Skip to content

Commit

Permalink
Add CI through GitHub Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
ForestOfLight committed Jan 25, 2025
1 parent b2cba46 commit 3cb0abb
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 1 deletion.
39 changes: 39 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: CI

on:
push:
branches:
- '**'
pull_request:
branches:
- '**'

jobs:
build:
runs-on: windows-latest

strategy:
matrix:
node-version: [16.x]

steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'

- name: Install dependencies
run: npm install

- name: Run tests with coverage
run: npm test

- name: Upload coverage report
uses: actions/upload-artifact@v3
with:
name: coverage-report
path: coverage
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"@vitest/coverage-v8": "^3.0.4"
},
"scripts": {
"test": "vitest"
"test": "vitest run --coverage"
},
"devDependencies": {
"axios": "^1.7.9",
Expand Down

0 comments on commit 3cb0abb

Please sign in to comment.