v3.35.0 #434
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: "All tests" | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
jobs: | |
lint-and-test: | |
name: "Lint, core tests, and spec compliance tests" | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: '16' | |
- run: yarn | |
- run: yarn build | |
- run: yarn lint | |
- run: yarn test-with-coverage && yarn report-coverage | |
- run: yarn integration-test | |
- run: yarn test262 | |
- run: yarn check-babel-tests | |
test-older-node: | |
name: "Test on older node versions" | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
# We support down to node 8, but mocha requires node 14. | |
- node_version: '14' | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ matrix.node_version }} | |
- run: yarn | |
# Do a fast build to avoid trying to run yarn on subprojects. Some | |
# website dependencies don't support old node versions, so yarn would | |
# fail for those. | |
- run: yarn fast-build | |
- run: yarn test-only | |
test-examples: | |
name: "Test example projects" | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- projects: "babel" | |
- projects: "react decaffeinate decaffeinate-parser coffee-lex" | |
- projects: "tslint apollo-client" | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: '16' | |
- run: yarn | |
- run: yarn fast-build | |
- run: yarn run-examples ${{ matrix.projects }} | |
perf-benchmark: | |
name: "Compare performance" | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
# Fetch all branches so we can compare with the default branch. | |
fetch-depth: 0 | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: '16' | |
- run: yarn | |
# Clone the jest repo and run an untimed benchmark first, since the first | |
# run immediately after cloning tends to be slower. | |
- run: yarn benchmark jest-dev | |
- run: yarn benchmark-compare | |
# The benchmark-compare script leaves a ./.perf-comparison/summary.txt file | |
# to be forwarded to the comment-perf.yml workflow via an artifact. We | |
# also need to send the PR number. See that file and | |
# https://securitylab.github.com/research/github-actions-preventing-pwn-requests | |
# for details of how the two fit together. | |
- run: echo ${{ github.event.number }} > ./.perf-comparison/pr-number.txt | |
- uses: actions/upload-artifact@v2 | |
with: | |
name: perf-comparison | |
path: .perf-comparison/ |