Skip to content

Commit

Permalink
chore: use @reporters/github test reporter for unit & e2e tests
Browse files Browse the repository at this point in the history
  • Loading branch information
flakey5 committed Oct 2, 2023
1 parent dadddfb commit 05a6e69
Show file tree
Hide file tree
Showing 3 changed files with 65 additions and 4 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
run: npm install

- name: Run Tests
run: npm run test:unit
run: node --test --test-reporter=@reporters/github --test-reporter-destination=stdout --test-reporter=spec --test-reporter-destination=stdout --loader=tsx ./tests/e2e/index.test.ts
e2e-test:
name: E2E Tests
runs-on: ubuntu-latest
Expand All @@ -49,4 +49,4 @@ jobs:
run: npm install

- name: Run Tests
run: npm run test:e2e
run: node --test --test-reporter=@reporters/github --test-reporter-destination=stdout --test-reporter=spec --test-reporter-destination=stdout --loader=tsx ./tests/unit/index.test.ts
60 changes: 60 additions & 0 deletions package-lock.json

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

5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,14 @@
"format": "prettier --check --write \"**/*.{ts,js,json,md,hbs}\"",
"prettier": "prettier --check \"**/*.{ts,js,json,md,hbs}\"",
"lint": "eslint ./src",
"test:unit": "node --test --test-reporter spec --loader tsx ./tests/unit/util.test.ts",
"test:e2e": "wrangler deploy --dry-run --outdir=dist && node --test --test-reporter spec --loader tsx ./tests/e2e/index.test.ts",
"test:unit": "node --test --test-reporter=spec --loader=tsx ./tests/unit/index.test.ts",
"test:e2e": "wrangler deploy --dry-run --outdir=dist && node --test --test-reporter=spec --loader=tsx ./tests/e2e/index.test.ts",
"build:handlebars": "node scripts/compile-handlebars.js"
},
"devDependencies": {
"@aws-sdk/client-s3": "^3.421.0",
"@cloudflare/workers-types": "^4.20230922.0",
"@reporters/github": "^1.5.3",
"@types/node": "^20.7.0",
"@typescript-eslint/eslint-plugin": "^6.7.3",
"@typescript-eslint/parser": "^6.7.3",
Expand Down

0 comments on commit 05a6e69

Please sign in to comment.