ci: github actions workflow improvements #3555
Workflow file for this run
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
name: Tests | |
on: | |
push: | |
branches: | |
- main | |
paths-ignore: ['*.md', 'docs/**'] | |
pull_request: | |
branches: | |
- main | |
paths-ignore: ['*.md', 'docs/**'] | |
permissions: | |
contents: read | |
jobs: | |
lint: | |
uses: ./.github/workflows/npm-script.yml | |
with: | |
npm-script: lint | |
smoke: | |
uses: ./.github/workflows/npm-script.yml | |
with: | |
os: 'ubuntu-latest,windows-2019' | |
node-versions: '14,16,18,20,22' | |
npm-script: test:smoke | |
test-node: | |
# TODO: Restore "mocha-github-actions-reporter" style reporting without relying on third party module | |
uses: ./.github/workflows/npm-script.yml | |
needs: smoke | |
with: | |
os: 'ubuntu-latest,windows-2019' | |
node-versions: '14,16,18,20,22' | |
npm-script: test:node | |
coverage: true | |
test-browser-local: | |
uses: ./.github/workflows/npm-script.yml | |
with: | |
browsers: ChromeHeadless | |
npm-script: test:browser | |
# test-browser-saucelabs: | |
# # Don't run forked 'pull_request' without saucelabs token | |
# if: github.event_name == 'push' || !github.event.pull_request.head.repo.fork | |
# needs: | |
# - lint | |
# - smoke | |
# - test-browser-local | |
# uses: ./.github/workflows/npm-script.yml | |
# secrets: inherit | |
# with: | |
# browsers: 'firefox@latest,chrome@latest,MicrosoftEdge@latest,safari@latest' | |
# npm-script: test:browser |