Add a Node ESM build to RUT (#6360) #5
This file contains hidden or 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: Test All Packages | |
on: push | |
env: | |
# make chromedriver detect installed Chrome version and download the corresponding driver | |
DETECT_CHROMEDRIVER_VERSION: true | |
jobs: | |
test: | |
name: Node.js and Browser (Chrome) Tests | |
runs-on: ubuntu-latest | |
steps: | |
# install Chrome first, so the correct version of webdriver can be installed by chromedriver when setting up the repo | |
- name: install Chrome stable | |
run: | | |
sudo apt-get update | |
sudo apt-get install google-chrome-stable | |
- uses: actions/checkout@v2 | |
- name: Set up Node (14) | |
uses: actions/setup-node@v2 | |
with: | |
node-version: 14.x | |
- name: Bump Node memory limit | |
run: echo "NODE_OPTIONS=--max_old_space_size=4096" >> $GITHUB_ENV | |
- name: Test setup and yarn install | |
run: | | |
cp config/ci.config.json config/project.json | |
yarn | |
- name: yarn build | |
run: yarn build | |
- name: Set start timestamp env var | |
run: echo "FIREBASE_CI_TEST_START_TIME=$(date +%s)" >> $GITHUB_ENV | |
- name: Run unit tests | |
run: | | |
xvfb-run yarn test:ci | |
node scripts/print_test_logs.js | |
- name: Generate coverage file | |
run: yarn ci:coverage | |
- name: Run coverage | |
uses: coverallsapp/github-action@master | |
with: | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
path-to-lcov: ./lcov-all.info | |
continue-on-error: true |