-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5f9d3f0
commit cd3c5d1
Showing
4 changed files
with
85 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
name: 🚀 Validation Pipeline | ||
concurrency: | ||
group: ${{ github.repository }}-${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
permissions: | ||
actions: write | ||
contents: read | ||
# Required to put a comment into the pull-request | ||
pull-requests: write | ||
jobs: | ||
lint: | ||
name: ⬣ ESLint | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: 🛑 Cancel Previous Runs | ||
uses: styfle/[email protected] | ||
|
||
- name: ⬇️ Checkout repo | ||
uses: actions/checkout@v3 | ||
|
||
- name: ⎔ Setup node | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 20 | ||
|
||
- name: 📥 Download deps | ||
uses: bahmutov/npm-install@v1 | ||
with: | ||
useLockFile: false | ||
|
||
- name: 🔬 Lint | ||
run: npm run lint:strict | ||
|
||
typecheck: | ||
name: 🔎 Type check | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: 🛑 Cancel Previous Runs | ||
uses: styfle/[email protected] | ||
- name: ⬇️ Checkout repo | ||
uses: actions/checkout@v3 | ||
- name: ⎔ Setup node | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 20 | ||
- name: 📥 Download deps | ||
uses: bahmutov/npm-install@v1 | ||
with: | ||
useLockFile: false | ||
- name: 🔎 Type check | ||
run: npm run typecheck | ||
|
||
vitest: | ||
name: ⚡ Unit Tests | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: 🛑 Cancel Previous Runs | ||
uses: styfle/[email protected] | ||
- name: ⬇️ Checkout repo | ||
uses: actions/checkout@v3 | ||
- name: ⎔ Setup node | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 20 | ||
- name: 📥 Download deps | ||
uses: bahmutov/npm-install@v1 | ||
with: | ||
useLockFile: false | ||
- name: Install dotenv cli | ||
run: npm install -g dotenv-cli | ||
- name: ⚡ Run vitest | ||
run: npm run test:cov | ||
- name: "Report Coverage" | ||
# Only works if you set `reportOnFailure: true` in your vite config as specified above | ||
if: always() | ||
uses: davelosert/vitest-coverage-report-action@v2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
npm run typecheck && npm run lint | ||
npm run typecheck && npm run lint:strict |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters