In #34955, we switched to Node.js v12 on master and 9.0.x. This causes the `aio_monitoring_job` CI job (which checks out files from the stable branch; currently 8.2.x) to start failing yarn's engines check (since the 8.2.x branch expects Node.js version <11). Example failure: https://circleci.com/gh/angular/angular/602499 Since the job is expected to run with files from both the stable and the master branches (and since the version of Node.js is not important here), this commit uses the `--ignore-engines` option to prevent failures due to Node.js version mismatch. NOTE: Typically, the stable and master branch are on the same Node.js version, because related PRs land on both master and the patch branch. One exception is during RC periods, when the stable branch is different than the patch branch. These periods are usually short, but in the case of 9.0.0 the period has lasted several months causing the CI environments between master and the stable branch to get significantly out-of-sync. PR Close #35004
34 lines
927 B
Bash
Executable File
34 lines
927 B
Bash
Executable File
#!/usr/bin/env bash
|
|
set +x -eu -o pipefail
|
|
|
|
(
|
|
readonly thisDir="$(cd $(dirname ${BASH_SOURCE[0]}); pwd)"
|
|
readonly aioDir="$(realpath $thisDir/..)"
|
|
|
|
readonly protractorConf="$aioDir/tests/deployment/e2e/protractor.conf.js"
|
|
readonly targetUrl="$1"
|
|
readonly minPwaScore="$2"
|
|
|
|
cd "$aioDir"
|
|
|
|
# Install dependencies.
|
|
# (Since this script may run on different branches (e.g. stable), ignore the engines check.)
|
|
echo -e "\nInstalling dependencies in '$aioDir'...\n-----"
|
|
yarn install --frozen-lockfile --ignore-engines --non-interactive
|
|
yarn update-webdriver
|
|
|
|
# Run checks for target URL.
|
|
echo -e "\nChecking '$targetUrl'...\n-----"
|
|
|
|
# Run basic e2e and deployment config tests.
|
|
yarn protractor "$protractorConf" --baseUrl "$targetUrl"
|
|
|
|
# Run PWA-score tests.
|
|
yarn test-pwa-score "$targetUrl" "$minPwaScore"
|
|
|
|
# Run a11y tests.
|
|
yarn test-a11y-score "$targetUrl"
|
|
|
|
echo -e "\nAll checks passed!"
|
|
)
|