Skip to content

Commit

Permalink
switch test suite to Deno due to coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
jarvisjiang committed May 19, 2024
1 parent 938773d commit c68cabf
Show file tree
Hide file tree
Showing 11 changed files with 213 additions and 1,274 deletions.
4 changes: 1 addition & 3 deletions .github/workflows/jsr-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@ jobs:
- run: pnpm install

- name: Run test cases
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
uses: denoland/setup-deno@v1
- run: pnpm test

publish-jsr:
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/npm-publish-github-packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ jobs:
- run: pnpm install

- name: Run test cases
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
uses: denoland/setup-deno@v1
- run: pnpm test

publish-gpr:
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ jobs:
- run: pnpm install

- name: Run test cases
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
uses: denoland/setup-deno@v1
- run: pnpm test

publish-npm:
Expand Down
6 changes: 2 additions & 4 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,10 @@ jobs:
- run: pnpm install

- name: Run test cases
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
uses: denoland/setup-deno@v1
- run: pnpm test

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
token: ${{ secrets.CODECOV_TOKEN }}
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
node_modules
dist
dist
coverage
5 changes: 5 additions & 0 deletions deno.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"imports": {
"@std/assert": "jsr:@std/assert@^0.225.2"
}
}
38 changes: 38 additions & 0 deletions deno.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@
"lint": "pnpm exec eslint src/",
"prebuild": "pnpm exec rimraf dist && pnpm run check && pnpm run lint",
"build": "pnpm exec rollup --config rollup.config.mjs",
"test": "bun test --coverage",
"pretest": "pnpm exec rimraf coverage",
"test": "deno test --coverage && deno coverage coverage && deno coverage coverage --lcov --output=coverage/cov_profile.lcov",
"prepublishOnly": "pnpm run build"
},
"repository": {
Expand All @@ -41,7 +42,6 @@
"Err"
],
"devDependencies": {
"@jest/globals": "^29.7.0",
"@typescript-eslint/eslint-plugin": "^7.9.0",
"@typescript-eslint/parser": "^7.9.0",
"eslint": "^8.57.0",
Expand Down
Loading

0 comments on commit c68cabf

Please sign in to comment.