Skip to content

Commit

Permalink
Merge pull request #28 from 21CSM/vitest-ci
Browse files Browse the repository at this point in the history
ci: add step to install node modules

ci: add unit testing to build.yml
  • Loading branch information
21CSM authored Sep 21, 2024
2 parents 257eaa2 + 68fd158 commit dfb71fc
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 8 deletions.
14 changes: 10 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Check flake health
- name: Check Flake Health
uses: DeterminateSystems/flake-checker-action@v9

build:
Expand All @@ -24,8 +24,14 @@ jobs:
uses: actions/checkout@v4
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v14
- name: Run the Magic Nix Cache
- name: Run Magic Nix Cache
uses: DeterminateSystems/magic-nix-cache-action@v8
- name: Run Nix flake checks
- name: Run Nix Flake Checks
run: |
nix flake check
nix flake check
- name: Install Dependencies
run: |
nix develop -c pnpm install
- name: Run Unit Tests
run: |
nix develop -c pnpm run test:unit
4 changes: 2 additions & 2 deletions .github/workflows/update-flake-lock.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ jobs:
uses: actions/checkout@v4
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v14
- name: Run the Magic Nix Cache
- name: Run Magic Nix Cache
uses: DeterminateSystems/magic-nix-cache-action@v8
- name: Check flake health
- name: Check Flake Health
uses: DeterminateSystems/flake-checker-action@v9
- name: Update flake.lock
uses: DeterminateSystems/update-flake-lock@v24
Expand Down
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@
"lint": "prettier --check . && eslint .",
"format": "prettier --write .",
"test:integration": "playwright test",
"test:integration:ui": "playwright test --ui",
"test:unit": "vitest"
"test:integration:ui": "playwright test --ui",
"test:unit": "vitest --run",
"test:unit:watch": "vitest"
},
"devDependencies": {
"@playwright/test": "^1.28.1",
Expand Down

0 comments on commit dfb71fc

Please sign in to comment.