Skip to content

Commit

Permalink
👷 chore(ci): Run tests on CI (#896)
Browse files Browse the repository at this point in the history
  • Loading branch information
duckception authored Oct 2, 2023
1 parent 00eba4e commit 9a338dc
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 3 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,7 @@ Runs on every pull request and validates whether the PR title follows the [Gitmo
## [🎨 lint.yml](lint.yml)

Checks the code style of the project.

## [🧑‍🔧 test.yml](test.yml)

Runs tests.
30 changes: 30 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: 🧑‍🔧 Test

on:
push:
branches:
- new-dawn
pull_request:

jobs:
test:
name: Run tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- uses: pnpm/action-setup@v2
with:
version: 8.7.6

- uses: actions/setup-node@v3
with:
node-version-file: ".nvmrc"
registry-url: https://registry.npmjs.org
cache: pnpm

- name: Install dependencies
run: pnpm install --frozen-lockfile

- name: Run tests
run: pnpm run test
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
"lint:unsafe": "biome check . --apply-unsafe",
"prepare": "husky install",
"sort-package-json": "sort-package-json 'package.json' 'packages/*/package.json' 'examples/*/package.json'",
"sort-package-json:check": "sort-package-json 'package.json' 'packages/*/package.json' 'examples/*/package.json' --check"
"sort-package-json:check": "sort-package-json 'package.json' 'packages/*/package.json' 'examples/*/package.json' --check",
"test": "turbo test"
},
"lint-staged": {
"package.json": "sort-package-json"
Expand Down
3 changes: 2 additions & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@
"lint": "biome check . --apply",
"lint:check": "biome check . --verbose",
"lint:unsafe": "biome check . --apply-unsafe",
"test": "vitest",
"test": "vitest run",
"test:watch": "vitest watch",
"types:check": "tsc --noEmit"
},
"devDependencies": {
Expand Down
3 changes: 2 additions & 1 deletion turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"pipeline": {
"build": {
"outputs": ["dist/**", "types/**"]
}
},
"test": {}
}
}

0 comments on commit 9a338dc

Please sign in to comment.