Skip to content

Commit

Permalink
ci(docs-infra): re-use env variable (angular#26138)
Browse files Browse the repository at this point in the history
PR Close angular#26138
  • Loading branch information
gkalpak authored and FrederikSchlemmer committed Jan 3, 2019
1 parent 00f5d13 commit cc15023
Show file tree
Hide file tree
Showing 5 changed files with 155 additions and 84 deletions.
6 changes: 5 additions & 1 deletion .circleci/config.yml
Expand Up @@ -256,7 +256,11 @@ jobs:
<<: *post_checkout
- restore_cache:
key: *cache_key
- run: xvfb-run --auto-servernum ./aio/scripts/test-production.sh
- run:
name: Run tests against the deployed apps
command: |
source "./scripts/ci/env.sh" print
xvfb-run --auto-servernum ./aio/scripts/test-production.sh $AIO_MIN_PWA_SCORE
workflows:
version: 2
Expand Down
9 changes: 5 additions & 4 deletions aio/package.json
Expand Up @@ -30,8 +30,8 @@
"setup-local": "yarn aio-use-local && yarn example-use-local",
"postsetup-local": "yarn postsetup",
"set-opensearch-url": "node --eval \"const sh = require('shelljs'); sh.set('-e'); sh.sed('-i', /PLACEHOLDER_URL/g, process.argv[1], 'dist/assets/opensearch.xml');\"",
"test-pwa-score-localhost": "concurrently --kill-others --success first \"http-server dist -p 4200 --silent\" \"yarn test-pwa-score http://localhost:4200 90\"",
"test-pwa-score": "node scripts/test-pwa-score",
"test-pwa-score-localhost": "run-p --race \"~~http-server dist -p 4200 --silent\" \"test-pwa-score http://localhost:4200 {1}\" --",
"example-e2e": "yarn example-check-local && node ./tools/examples/run-example-e2e",
"example-lint": "tslint -c \"content/examples/tslint.json\" \"content/examples/**/*.ts\" -e \"content/examples/styleguide/**/*.avoid.ts\"",
"example-use-local": "node tools/ng-packages-installer overwrite ./tools/examples/shared --debug",
Expand All @@ -52,7 +52,7 @@
"tools-lint": "tslint -c \"tools/tslint.json\" \"tools/firebase-test-utils/**/*.ts\"",
"tools-test": "./scripts/deploy-to-firebase.test.sh && yarn docs-test && yarn boilerplate:test && jasmine tools/ng-packages-installer/index.spec.js && yarn firebase-utils-test",
"preserve-and-sync": "yarn docs",
"serve-and-sync": "concurrently --kill-others \"yarn docs-watch --watch-only\" \"yarn start\"",
"serve-and-sync": "run-p \"start\" \"docs-watch --watch-only\"",
"boilerplate:add": "node ./tools/examples/example-boilerplate add",
"boilerplate:remove": "node ./tools/examples/example-boilerplate remove",
"boilerplate:test": "node tools/examples/test.js",
Expand All @@ -64,7 +64,8 @@
"~~check-env": "node scripts/check-environment",
"~~clean-generated": "node --eval \"require('shelljs').rm('-rf', 'src/generated')\"",
"~~build": "ng build",
"post~~build": "yarn build-404-page"
"post~~build": "yarn build-404-page",
"~~http-server": "http-server"
},
"engines": {
"node": ">=10.9.0 <11.0.0",
Expand Down Expand Up @@ -105,7 +106,6 @@
"chalk": "^2.1.0",
"cjson": "^0.5.0",
"codelyzer": "~4.2.1",
"concurrently": "^3.4.0",
"cross-spawn": "^5.1.0",
"css-selector-parser": "^1.3.0",
"dgeni": "^0.4.7",
Expand Down Expand Up @@ -139,6 +139,7 @@
"lighthouse": "^2.5.0",
"lodash": "^4.17.4",
"lunr": "^2.1.0",
"npm-run-all": "^4.1.3",
"protractor": "^5.2.0",
"rehype": "^4.0.0",
"rehype-slug": "^2.0.0",
Expand Down
2 changes: 1 addition & 1 deletion aio/scripts/test-production.sh
Expand Up @@ -6,7 +6,7 @@ set +x -eu -o pipefail
readonly aioDir="$(realpath $thisDir/..)"

readonly protractorConf="$aioDir/tests/deployment/e2e/protractor.conf.js"
readonly minPwaScore="95"
readonly minPwaScore="$1"
readonly urls=(
"https://angular.io/"
"https://next.angular.io/"
Expand Down

0 comments on commit cc15023

Please sign in to comment.