-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update test case and & coverage support in readme
- Loading branch information
1 parent
fc38d1e
commit 56b544c
Showing
14 changed files
with
2,277 additions
and
40 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,40 @@ | ||
name: Run test cases | ||
|
||
on: [pull_request, push] | ||
|
||
jobs: | ||
run-test-cases: | ||
runs-on: ${{ matrix.os }} | ||
|
||
strategy: | ||
matrix: | ||
os: [ | ||
ubuntu-latest, | ||
windows-latest, | ||
macos-latest, | ||
] | ||
node-version: [16.x, 18.x, 20.x] | ||
|
||
steps: | ||
- name: Get branch name | ||
shell: bash | ||
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})" | ||
id: get_branch | ||
|
||
- uses: actions/checkout@v2 | ||
|
||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v1 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
|
||
- name: Install packages and run test cases | ||
run: | | ||
npm install | ||
npm run test | ||
- name: Coveralls (Uploading test report) | ||
if: ${{ steps.get_branch.outputs.branch == 'main' }} | ||
uses: coverallsapp/github-action@main | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} |
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
Oops, something went wrong.