Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce testing with Vitest #745

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion .github/workflows/test.yml → .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: test
name: ci
on:
push:
pull_request:
Expand Down Expand Up @@ -58,3 +58,14 @@ jobs:
run: pnpm install
- name: Run build
run: pnpm run build
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
with:
version: latest
- name: Install modules
run: pnpm install
- name: Run tests
run: pnpm test
Empty file added mocks/obsidian.ts
Empty file.
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"format": "prettier --check src",
"tsc": "tsc --noEmit",
"svelte": "svelte-check",
"all": "pnpm run tsc && pnpm run svelte && pnpm run format && pnpm run lint"
"all": "pnpm run tsc && pnpm run svelte && pnpm run format && pnpm run lint",
"test": "vitest"
},
"keywords": [],
"author": "",
Expand Down Expand Up @@ -47,7 +48,8 @@
"svelte-check": "^3.8.2",
"svelte-preprocess": "^5.1.4",
"tslib": "^2.6.3",
"typescript": "^5.5.2"
"typescript": "^5.5.2",
"vitest": "^1.6.0"
},
"dependencies": {
"buffer": "^6.0.3",
Expand Down
Loading
Loading