-
Notifications
You must be signed in to change notification settings - Fork 1
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
344d1cf
commit 4c23e55
Showing
1 changed file
with
44 additions
and
0 deletions.
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,44 @@ | ||
# For more information on running Github CI with Node: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs | ||
name: GitHub CI Tests | ||
run-name: Testing commit by ${{ github.actor }} | ||
|
||
# when pipeline is triggered | ||
on: | ||
# manual trigger workflow in UI | ||
workflow_dispatch: | ||
# commit on any branch | ||
push: | ||
# only trigger on branches, not on tags | ||
branches: ['**'] | ||
# during pull request | ||
pull_request: | ||
|
||
# cancel any ongoing job in the branch if there is one more recent | ||
concurrency: | ||
group: ${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
install-build-test: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [18.x] | ||
|
||
steps: | ||
- run: echo "Job was automatically triggered by a ${{ github.event_name }} event on ${{ github.ref }} - ${{ github.repository }}." | ||
- uses: actions/checkout@v4 | ||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Check versions | ||
run: echo "Node version:" && node -v && echo "NPM version:" && npm -v | ||
- name: Install dependencies | ||
run: npm install | ||
- name: Build | ||
run: npm run build | ||
- name: Test | ||
run: npm run test | ||
- run: echo "Job status ${{ job.status }}." |