2017-07-13 15:16:02 -04:00
# Configuration file for https://circleci.com/gh/angular/angular
# Note: YAML anchors allow an object to be re-used, reducing duplication.
# The ampersand declares an alias for an object, then later the `<<: *name`
# syntax dereferences it.
# See http://blog.daemonl.com/2016/02/yaml.html
# To validate changes, use an online parser, eg.
# http://yaml-online-parser.appspot.com/
2018-10-27 03:25:45 -04:00
# Note that the browser docker image comes with Chrome and Firefox preinstalled. This is just
# needed for jobs that run tests without Bazel. Bazel runs tests with browsers that will be
# fetched by the Webtesting rules. Therefore for jobs that run tests with Bazel, we don't need a
# docker image with browsers pre-installed.
2019-09-11 05:09:47 -04:00
# **NOTE 1**: Pin to exact images using an ID (SHA). See https://circleci.com/docs/2.0/circleci-images/#using-a-docker-image-id-to-pin-an-image-to-a-fixed-version.
# (Using the tag in not necessary when pinning by ID, but include it anyway for documentation purposes.)
# **NOTE 2**: If you change the version of the docker images, also change the `cache_key` suffix.
# **NOTE 3**: If you change the version of the `*-browsers` docker image, make sure the
2019-02-01 16:40:33 -05:00
# `CI_CHROMEDRIVER_VERSION_ARG` env var (in `.circleci/env.sh`) points to a ChromeDriver
# version that is compatible with the Chrome version in the image.
2019-09-11 05:09:47 -04:00
var_1 : &default_docker_image circleci/node:10.16@sha256:75c05084fff4afa3683a03c5a04a4a3ad95c536ff2439d8fe14e7e1f5c58b09a
var_2 : &browsers_docker_image circleci/node:10.16-browsers@sha256:d2a96fe1cbef51257ee626b5f645e64dade3e886f00ba9cb7e8ea65b4efe8db1
2019-01-31 17:57:26 -05:00
# We don't want to include the current branch name in the cache key because that would prevent
# PRs from being able to restore the cache since the branch names are always different for PRs.
# The cache key should only consist of dynamic values that change whenever something in the
2019-02-04 11:11:26 -05:00
# cache changes. For example:
# 1) yarn lock file changes --> cached "node_modules" are different.
# 2) bazel repository definitions change --> cached bazel repositories are different.
2019-02-05 13:30:26 -05:00
# **NOTE 1 **: If you change the cache key prefix, also sync the restore_cache fallback to match.
# **NOTE 2 **: Keep the static part of the cache key as prefix to enable correct fallbacks.
# See https://circleci.com/docs/2.0/caching/#restoring-cache for how prefixes work in CircleCI.
2019-06-17 13:17:19 -04:00
var_3 : &cache_key v3-angular-node-10.16-{{ checksum "yarn.lock" }}-{{ checksum "WORKSPACE" }}-{{ checksum "packages/bazel/package.bzl" }}-{{ checksum "aio/yarn.lock" }}
2019-07-25 10:47:02 -04:00
var_3_win : &cache_key_win v4-angular-win-node-12.0-{{ checksum "yarn.lock" }}-{{ checksum "WORKSPACE" }}-{{ checksum "packages/bazel/package.bzl" }}-{{ checksum "aio/yarn.lock" }}
2017-12-12 04:23:09 -05:00
2019-02-19 16:15:42 -05:00
# Initializes the CI environment by setting up common environment variables.
2019-02-17 13:38:37 -05:00
var_4 : &init_environment
2018-10-17 12:19:15 -04:00
run :
2019-02-21 11:20:51 -05:00
name : Initializing environment (setting up variables, overwriting Yarn)
# Overwrite the yarn installed in the docker container with our own version.
2019-02-17 13:38:37 -05:00
command : |
2019-02-21 11:20:51 -05:00
./.circleci/env.sh
2019-08-27 10:41:35 -04:00
ourYarn=$(realpath ./third_party/github.com/yarnpkg/yarn/releases/download/v1.17.3/bin/yarn.js)
2019-02-21 11:20:51 -05:00
sudo chmod a+x $ourYarn
sudo ln -fs $ourYarn /usr/local/bin/yarn
2019-02-19 16:15:42 -05:00
echo "Yarn version: $(yarn --version)"
2018-04-13 14:53:48 -04:00
2019-02-22 12:30:19 -05:00
# Add GitHub to known hosts.
mkdir -p ~/.ssh
echo 'github.com ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ==' >> ~/.ssh/known_hosts
# use git+ssh instead of https
git config --global url."ssh://git@github.com".insteadOf "https://github.com" || true
git config --global gc.auto 0 || true
2019-07-25 10:47:02 -04:00
var_4_win : &init_environment_win
run :
# Install Bazel pre-requisites that aren't in the preconfigured CircleCI Windows VM.
name : Setup windows node environment
command : ./.circleci/windows-env.ps1
2019-02-22 12:30:19 -05:00
2018-08-02 00:02:36 -04:00
var_5 : &setup_bazel_remote_execution
run :
name : "Setup bazel RBE remote execution"
2018-12-01 19:08:15 -05:00
command : |
2019-06-17 13:17:19 -04:00
# We need ensure that the same default digest is used for encoding and decoding
# with openssl. Openssl versions might have different default digests which can
# cause decryption failures based on the openssl version. https://stackoverflow.com/a/39641378/4317734
openssl aes-256-cbc -d -in .circleci/gcp_token -md md5 -k "$CI_REPO_NAME" -out /home/circleci/.gcp_credentials
2018-12-01 19:08:15 -05:00
echo "export GOOGLE_APPLICATION_CREDENTIALS=/home/circleci/.gcp_credentials" >> $BASH_ENV
test(ivy): update Material to recent commit from master branch (#31569)
Previously, the ivy-2019 branch of the Material (aka components) repo was
used, which contains some changes that were necessary to work with Ivy.
These changes are not longer necessary, as Material's master branch is
fully working with Ivy today. To be up-to-date with recent Material
development and its support for more recent dependencies, e.g. TypeScript,
it is desirable for us to be on a newer version of Material.
This commit moves the Material tests away from the ivy-2019 branch, to a
recent commit on master. We are not targeting the master branch itself,
as that would introduce a moving target into Angular's CI checks, which
is undesirable.
Lastly, the usage of gulp to run Material's tests is changed into using
Bazel, as Material itself is now also built with Bazel.
PR Close #31569
2019-06-13 15:06:14 -04:00
./.circleci/setup-rbe.sh .bazelrc.user
2018-08-02 00:02:36 -04:00
2018-10-27 03:25:45 -04:00
# Settings common to each job
var_6 : &job_defaults
working_directory : ~/ng
docker :
- image : *default_docker_image
2019-07-25 10:47:02 -04:00
var_6_win : &job_defaults_win
working_directory : ~/ng
resource_class : windows.medium
# CircleCI windows VMs do have the GitBash shell available:
# https://github.com/CircleCI-Public/windows-preview-docs#shells
# But in this specific case we really should not use it because Bazel must not be ran from
# GitBash. These issues discuss why:
# https://github.com/bazelbuild/bazel/issues/5751
# https://github.com/bazelbuild/bazel/issues/5724#issuecomment-410194038
# https://github.com/bazelbuild/bazel/issues/6339#issuecomment-441600879
shell : powershell.exe -ExecutionPolicy Bypass
machine :
# Preview image that includes the following:
# - Visual Studio 2019 build tools
# - Node 12
# - yarn 1.17
# - Python 3 3.7.4
image : windows-server-2019-vs2019:201908-02
2018-10-27 03:25:45 -04:00
2019-03-11 12:00:49 -04:00
# After checkout, rebase on top of target branch.
2018-10-31 16:27:38 -04:00
var_7 : &post_checkout
2019-01-31 09:14:59 -05:00
run :
2019-03-11 12:00:49 -04:00
name : Rebase PR on target branch
2019-01-31 09:14:59 -05:00
command : >
if [[ -n "${CIRCLE_PR_NUMBER}" ]]; then
2019-03-11 12:00:49 -04:00
# User is required for rebase.
2019-01-31 09:14:59 -05:00
git config user.name "angular-ci"
git config user.email "angular-ci"
2019-03-11 12:00:49 -04:00
# Rebase PR on top of target branch.
node tools/rebase-pr.js angular/angular ${CIRCLE_PR_NUMBER}
else
echo "This build is not over a PR, nothing to do."
2019-01-31 09:14:59 -05:00
fi
2019-07-25 10:47:02 -04:00
var_7_win : &post_checkout_win
run :
name : Rebase PR on target branch
command : >
if (Test-Path env:CIRCLE_PR_NUMBER) {
git config user.name "angular-ci"
git config user.email "angular-ci"
node tools\rebase-pr.js angular/angular-cli $env:CIRCLE_PR_NUMBER
} else {
echo "This build is not over a PR, nothing to do."
}
2017-07-13 15:16:02 -04:00
2018-10-31 16:27:38 -04:00
var_8 : &yarn_install
2018-10-27 03:25:45 -04:00
run :
name : Running Yarn install
2019-01-31 07:33:23 -05:00
command : |
# Yarn's requests sometimes take more than 10mins to complete.
# Print something to stdout, to prevent CircleCI from failing due to not output.
while true; do sleep 60; echo "[`date`] Keeping alive..."; done &
KEEP_ALIVE_PID=$!
yarn install --frozen-lockfile --non-interactive
kill $KEEP_ALIVE_PID
2018-10-27 03:25:45 -04:00
2018-10-31 16:27:38 -04:00
var_9 : &setup_circleci_bazel_config
2018-10-27 03:25:45 -04:00
run :
name : Setting up CircleCI bazel configuration
2019-08-21 19:04:09 -04:00
command : sudo cp .circleci/bazel.linux.rc $HOME/.bazelrc
2019-07-25 10:47:02 -04:00
var_9_win : &setup_circleci_bazel_config_win
run :
name : Setting up CircleCI bazel configuration
2019-08-21 19:04:09 -04:00
command : copy .circleci\bazel.windows.rc $env:USERPROFILE\.bazelrc
2018-10-27 03:25:45 -04:00
2019-02-17 13:38:37 -05:00
var_10 : &restore_cache
2019-02-05 13:30:26 -05:00
restore_cache :
keys :
- *cache_key
# This fallback should be the cache_key without variables.
2019-06-17 13:17:19 -04:00
- v3-angular-node-10.16-
2019-07-25 10:47:02 -04:00
var_10_win : &restore_cache_win
restore_cache :
keys :
- *cache_key_win
# This fallback should be the cache_key without variables.
- v4-angular-win-node-12.0-
2019-02-05 13:30:26 -05:00
2019-02-17 12:29:48 -05:00
# Branch filter that can be specified for jobs that should only run on publish branches
# (e.g. master or the patch branch)
2019-06-21 17:45:19 -04:00
var_11 : &publish_branches_filter
2019-02-17 12:29:48 -05:00
branches :
only :
- master
# e.g. 7.0.x, 7.1.x, etc.
- /\d+\.\d+\.x/
2019-02-25 04:19:07 -05:00
# Workspace initially persisted by the `install` job, and then enhanced by `test_aio` and
# `build-npm-packages`.
2019-02-22 12:30:19 -05:00
# https://circleci.com/docs/2.0/workflows/#using-workspaces-to-share-data-among-jobs
# https://circleci.com/blog/deep-diving-into-circleci-workspaces/
2019-06-21 17:45:19 -04:00
var_12 : &attach_workspace
2019-02-25 04:19:07 -05:00
attach_workspace :
at : ~/
2019-02-22 12:30:19 -05:00
2019-06-21 17:45:19 -04:00
var_13 : ¬ify_caretaker_on_fail
run :
when : on_fail
name : Notify caretaker about failure
# `$SLACK_CARETAKER_WEBHOOK_URL` is a secret env var defined in CircleCI project settings.
# The URL comes from https://angular-team.slack.com/apps/A0F7VRE7N-circleci.
command : |
2019-06-27 15:27:22 -04:00
notificationJson="{\"text\":\":x: \`$CIRCLE_JOB\` job for $CIRCLE_BRANCH branch failed on build $CIRCLE_BUILD_NUM: $CIRCLE_BUILD_URL :scream:\"}"
2019-06-21 17:45:19 -04:00
curl --request POST --header "Content-Type: application/json" --data "$notificationJson" $SLACK_CARETAKER_WEBHOOK_URL
var_14 : ¬ify_dev_infra_on_fail
run :
when : on_fail
name : Notify dev-infra about failure
# `$SLACK_DEV_INFRA_CI_FAILURES_WEBHOOK_URL` is a secret env var defined in CircleCI project settings.
# The URL comes from https://angular-team.slack.com/apps/A0F7VRE7N-circleci.
command : |
2019-06-27 15:27:22 -04:00
notificationJson="{\"text\":\":x: \`$CIRCLE_JOB\` job for $CIRCLE_BRANCH branch failed on build $CIRCLE_BUILD_NUM: $CIRCLE_BUILD_URL :scream:\"}"
2019-06-21 17:45:19 -04:00
curl --request POST --header "Content-Type: application/json" --data "$notificationJson" $SLACK_DEV_INFRA_CI_FAILURES_WEBHOOK_URL
2019-07-23 16:54:56 -04:00
# Cache key for the Material unit tests job. **Note** when updating the SHA in the cache keys,
# also update the SHA for the "MATERIAL_REPO_COMMIT" environment variable.
2019-09-05 16:27:50 -04:00
var_15 : &material_unit_tests_cache_key v4-angular-material-2817c9e2faa4140342336987a692d5dd30bf24c2
2019-07-23 16:54:56 -04:00
var_16 : &material_unit_tests_cache_key_short v4-angular-material
2017-06-02 20:03:15 -04:00
version : 2
jobs :
2019-02-22 16:33:53 -05:00
setup :
2017-07-13 15:16:02 -04:00
<< : *job_defaults
2017-06-02 20:03:15 -04:00
steps :
2019-01-31 09:14:59 -05:00
- checkout
- *post_checkout
2019-02-22 12:30:19 -05:00
# This cache is saved in the build-npm-packages so that Bazel cache is also included.
2019-02-05 13:30:26 -05:00
- *restore_cache
2019-02-17 13:38:37 -05:00
- *init_environment
2018-10-27 03:25:45 -04:00
- *yarn_install
2019-02-22 12:30:19 -05:00
- run : yarn --cwd aio install --frozen-lockfile --non-interactive
2019-02-25 04:19:07 -05:00
# Make the bazel directories and add a file to them if they don't exist already so that
# persist_to_workspace does not fail.
- run : |
if [ ! -d ~/bazel_repository_cache ]; then
mkdir ~/bazel_repository_cache
touch ~/bazel_repository_cache/MARKER
fi
2019-02-22 12:30:19 -05:00
# Persist any changes at this point to be reused by further jobs.
2019-02-25 04:19:07 -05:00
# **NOTE 1 **: Folders persisted here should be kept in sync with `var_13: &attach_workspace`.
# **NOTE 2 **: To add new content to the workspace, always persist on the same root.
2019-02-22 12:30:19 -05:00
- persist_to_workspace :
2019-02-25 04:19:07 -05:00
root : ~/
2019-02-22 12:30:19 -05:00
paths :
2019-02-25 04:19:07 -05:00
- ./ng
- ./bazel_repository_cache
2019-02-22 12:30:19 -05:00
lint :
<< : *job_defaults
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-22 12:30:19 -05:00
- *init_environment
2018-01-25 12:55:27 -05:00
2018-12-05 15:16:14 -05:00
- run : 'yarn bazel:format -mode=check ||
(echo "BUILD files not formatted. Please run ''yarn bazel:format''" ; exit 1)'
2018-03-01 10:15:30 -05:00
# Run the skylark linter to check our Bazel rules
2018-12-05 15:16:14 -05:00
- run : 'yarn bazel:lint ||
(echo -e "\n.bzl files have lint errors. Please run ''yarn bazel:lint-fix''"; exit 1)'
2018-01-25 12:55:27 -05:00
2019-02-19 16:15:42 -05:00
- run : yarn gulp lint
2019-09-10 06:56:38 -04:00
- run : node tools/verify-codeownership
2017-06-21 00:08:20 -04:00
2018-04-23 14:46:02 -04:00
test :
2017-07-13 15:16:02 -04:00
<< : *job_defaults
2018-03-07 20:26:03 -05:00
resource_class : xlarge
2017-06-14 19:38:27 -04:00
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-02-06 03:19:51 -05:00
- *setup_circleci_bazel_config
2018-08-02 00:02:36 -04:00
# Setup remote execution and run RBE-compatible tests.
- *setup_bazel_remote_execution
2019-07-25 10:40:05 -04:00
- run :
command : yarn bazel test //... --build_tag_filters=-ivy-only --test_tag_filters=-ivy-only
no_output_timeout : 20m
2017-12-13 12:18:16 -05:00
2018-06-05 14:38:46 -04:00
# Temporary job to test what will happen when we flip the Ivy flag to true
test_ivy_aot :
<< : *job_defaults
resource_class : xlarge
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-02-06 03:19:51 -05:00
- *setup_circleci_bazel_config
2018-08-02 00:02:36 -04:00
- *setup_bazel_remote_execution
2018-10-27 03:25:45 -04:00
2018-11-10 05:27:08 -05:00
# We need to explicitly specify the --symlink_prefix option because otherwise we would
# not be able to easily find the output bin directory when uploading artifacts for size
# measurements.
2019-07-25 10:40:05 -04:00
- run :
command : yarn test-ivy-aot //... --symlink_prefix=dist/
no_output_timeout : 20m
2018-11-10 05:27:08 -05:00
# Publish bundle artifacts which will be used to calculate the size change. **Note**: Make
# sure that the size plugin from the Angular robot fetches the artifacts from this CircleCI
# job (see .github/angular-robot.yml). Additionally any artifacts need to be stored with the
# following path format: "{projectName}/{context}/{fileName}". This format is necessary
# because otherwise the bot is not able to pick up the artifacts from CircleCI. See:
# https://github.com/angular/github-robot/blob/master/functions/src/plugins/size.ts#L392-L394
- store_artifacts :
path : dist/bin/packages/core/test/bundling/hello_world/bundle.min.js
destination : core/hello_world/bundle
- store_artifacts :
path : dist/bin/packages/core/test/bundling/todo/bundle.min.js
destination : core/todo/bundle
- store_artifacts :
path : dist/bin/packages/core/test/bundling/hello_world/bundle.min.js.br
destination : core/hello_world/bundle.br
- store_artifacts :
path : dist/bin/packages/core/test/bundling/todo/bundle.min.js.br
destination : core/todo/bundle.br
2017-06-14 19:38:27 -04:00
2019-07-19 06:35:22 -04:00
# This job is currently a PoC for running tests on SauceLabs via bazel. It runs a subset of the
# tests in `legacy-unit-tests-saucelabs` (see
# [BUILD.bazel](https://github.com/angular/angular/blob/ef44f51d5/BUILD.bazel#L66-L92)).
#
# NOTE: This is currently limited to master builds only. See the `default_workflow` configuration.
2019-03-12 14:44:03 -04:00
test_saucelabs_bazel :
2018-12-18 01:09:39 -05:00
<< : *job_defaults
# In order to avoid the bottleneck of having a slow host machine, we acquire a better
# container for this job. This is necessary because we launch a lot of browsers concurrently
# and therefore the tunnel and Karma need to process a lot of file requests and tests.
resource_class : xlarge
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2018-12-18 01:09:39 -05:00
- *init_environment
2019-03-04 15:40:50 -05:00
- *setup_circleci_bazel_config
2018-12-18 01:09:39 -05:00
- run :
2019-08-13 13:47:11 -04:00
name : Run Bazel tests in saucelabs
# All web tests are contained within a single //:test_web_all target for Saucelabs
# as running each set of tests as a separate target will attempt to acquire too
# many browsers on Saucelabs (7 per target currently) and some tests will always
# fail to acquire browsers. For example:
# 14 02 2019 19:52:33.170:WARN [launcher]: chrome beta on SauceLabs have not captured in 180000 ms, killing.
# //packages/forms/test:web_test_sauce TIMEOUT in 315.0s
command : |
./scripts/saucelabs/run-bazel-via-tunnel.sh \
--tunnel-id angular-${CIRCLE_BUILD_NUM}-${CIRCLE_NODE_INDEX} \
--username $SAUCE_USERNAME \
--key $(echo $SAUCE_ACCESS_KEY | rev) \
yarn bazel test //:test_web_all
2019-07-25 10:40:05 -04:00
no_output_timeout : 20m
2019-06-21 17:45:58 -04:00
- *notify_dev_infra_on_fail
2018-12-18 01:09:39 -05:00
2018-10-25 07:01:24 -04:00
test_aio :
2018-10-10 16:55:45 -04:00
<< : *job_defaults
2018-10-27 03:25:45 -04:00
docker :
# Needed because the AIO tests and the PWA score test depend on Chrome being available.
- image : *browsers_docker_image
2018-10-10 16:55:45 -04:00
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2018-10-10 16:55:45 -04:00
# Build aio
- run : yarn --cwd aio build --progress=false
# Lint the code
- run : yarn --cwd aio lint
# Run unit tests
2019-02-01 17:13:51 -05:00
- run : yarn --cwd aio test --progress=false --watch=false
2018-10-10 16:55:45 -04:00
# Run e2e tests
2019-02-01 17:13:51 -05:00
- run : yarn --cwd aio e2e --configuration=ci
2019-06-13 17:25:35 -04:00
# Run PWA-score tests
- run : yarn --cwd aio test-pwa-score-localhost $CI_AIO_MIN_PWA_SCORE
2019-07-03 19:34:32 -04:00
# Run accessibility tests
- run : yarn --cwd aio test-a11y-score-localhost
2019-06-13 17:25:35 -04:00
# Check the bundle sizes.
- run : yarn --cwd aio payload-size
2018-10-10 16:55:45 -04:00
# Run unit tests for Firebase redirects
- run : yarn --cwd aio redirects-test
2018-10-25 07:01:24 -04:00
deploy_aio :
<< : *job_defaults
2018-10-27 03:25:45 -04:00
docker :
# Needed because before deploying the deploy-production script runs the PWA score tests.
- image : *browsers_docker_image
2018-10-25 07:01:24 -04:00
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2018-10-18 07:49:30 -04:00
# Deploy angular.io to production (if necessary)
2019-04-25 06:59:16 -04:00
- run : setPublicVar_CI_STABLE_BRANCH
2018-10-22 06:06:20 -04:00
- run : yarn --cwd aio deploy-production
2018-10-10 16:55:45 -04:00
test_aio_local :
<< : *job_defaults
2018-10-27 03:25:45 -04:00
docker :
# Needed because the AIO tests and the PWA score test depend on Chrome being available.
- image : *browsers_docker_image
2018-10-10 16:55:45 -04:00
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2018-10-10 16:55:45 -04:00
# Build aio (with local Angular packages)
2019-08-03 11:14:40 -04:00
- run : yarn --cwd aio build-local-ci
2018-10-10 16:55:45 -04:00
# Run unit tests
2019-02-01 17:13:51 -05:00
- run : yarn --cwd aio test --progress=false --watch=false
2018-10-10 16:55:45 -04:00
# Run e2e tests
2019-02-01 17:13:51 -05:00
- run : yarn --cwd aio e2e --configuration=ci
2019-06-13 17:25:35 -04:00
# Run PWA-score tests
- run : yarn --cwd aio test-pwa-score-localhost $CI_AIO_MIN_PWA_SCORE
2019-06-14 06:01:37 -04:00
# Check the bundle sizes.
- run : yarn --cwd aio payload-size aio-local
2018-10-10 16:55:45 -04:00
2018-11-05 12:21:27 -05:00
test_aio_local_ivy :
<< : *job_defaults
2019-04-30 19:24:13 -04:00
docker :
# Needed because the AIO tests and the PWA score test depend on Chrome being available.
- image : *browsers_docker_image
2018-11-05 12:21:27 -05:00
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2018-11-05 12:21:27 -05:00
# Build aio with Ivy (using local Angular packages)
2019-08-03 11:14:40 -04:00
- run : yarn --cwd aio build-with-ivy-ci
2019-04-30 19:24:13 -04:00
# Run unit tests
- run : yarn --cwd aio test --progress=false --watch=false
# Run e2e tests
- run : yarn --cwd aio e2e --configuration=ci
2019-06-13 17:25:35 -04:00
# Run PWA-score tests
- run : yarn --cwd aio test-pwa-score-localhost $CI_AIO_MIN_PWA_SCORE
2019-06-14 06:01:37 -04:00
# Check the bundle sizes.
- run : yarn --cwd aio payload-size aio-local-ivy
2018-11-05 12:21:27 -05:00
2018-10-10 16:55:45 -04:00
test_aio_tools :
<< : *job_defaults
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2018-10-10 16:55:45 -04:00
# Install
- run : yarn --cwd aio install --frozen-lockfile --non-interactive
- run : yarn --cwd aio extract-cli-command-docs
# Run tools tests
- run : yarn --cwd aio tools-test
- run : ./aio/aio-builds-setup/scripts/test.sh
2019-01-06 09:37:55 -05:00
test_docs_examples :
2018-10-10 16:55:45 -04:00
<< : *job_defaults
2018-10-27 03:25:45 -04:00
docker :
# Needed because the example e2e tests depend on Chrome.
- image : *browsers_docker_image
2019-02-26 14:24:04 -05:00
parallelism : 4
2019-03-04 18:33:06 -05:00
resource_class : xlarge
2018-10-10 16:55:45 -04:00
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2018-10-10 16:55:45 -04:00
# Install aio
- run : yarn --cwd aio install --frozen-lockfile --non-interactive
2019-01-06 09:37:55 -05:00
# Run examples tests. The "CIRCLE_NODE_INDEX" will be set if "parallelism" is enabled.
2019-01-07 13:29:25 -05:00
# Since the parallelism is set to "3", there will be three parallel CircleCI containers
# with either "0", "1" or "2" as node index. This can be passed to the "--shard" argument.
2019-09-05 11:55:40 -04:00
- run : yarn --cwd aio example-e2e --setup --local --cliSpecsConcurrency=5 --shard=${CIRCLE_NODE_INDEX}/${CIRCLE_NODE_TOTAL} --retry 2
2018-10-10 16:55:45 -04:00
2019-02-05 16:20:05 -05:00
test_docs_examples_ivy :
<< : *job_defaults
docker :
# Needed because the example e2e tests depend on Chrome.
- image : *browsers_docker_image
2019-03-04 18:33:06 -05:00
resource_class : xlarge
2019-02-26 14:24:04 -05:00
# We increase the parallelism here to five while the "test_docs_examples" job runs with
# a parallelism of four. This is necessary because this job also need to run NGCC which
# takes up more time and we don't want these jobs to impact the overall CI turnaround.
parallelism : 5
2019-02-05 16:20:05 -05:00
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-02-05 16:20:05 -05:00
# Install aio
- run : yarn --cwd aio install --frozen-lockfile --non-interactive
2019-02-26 14:17:25 -05:00
# Rename the Ivy packages dist folder to "dist/packages-dist" as the AIO
# package installer picks up the locally built packages from that location.
# *Note*: We could also adjust the packages installer, but given we won't have
# two different folders of Angular distributions in the future, we should keep
# the packages installer unchanged.
- run : mv dist/packages-dist-ivy-aot dist/packages-dist
2019-02-05 16:20:05 -05:00
# Run examples tests with ivy. The "CIRCLE_NODE_INDEX" will be set if "parallelism" is enabled.
# Since the parallelism is set to "3", there will be three parallel CircleCI containers
# with either "0", "1" or "2" as node index. This can be passed to the "--shard" argument.
2019-09-05 11:55:40 -04:00
- run : yarn --cwd aio example-e2e --setup --local --ivy --cliSpecsConcurrency=5 --shard=${CIRCLE_NODE_INDEX}/${CIRCLE_NODE_TOTAL} --retry 2
2019-02-05 16:20:05 -05:00
2018-10-17 12:19:15 -04:00
# This job should only be run on PR builds, where `CI_PULL_REQUEST` is not `false`.
2018-05-09 13:54:13 -04:00
aio_preview :
<< : *job_defaults
environment :
AIO_SNAPSHOT_ARTIFACT_PATH : &aio_preview_artifact_path 'aio/tmp/snapshot.tgz'
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2018-10-17 12:19:15 -04:00
- run : ./aio/scripts/build-artifacts.sh $AIO_SNAPSHOT_ARTIFACT_PATH $CI_PULL_REQUEST $CI_COMMIT
2018-05-09 13:54:13 -04:00
- store_artifacts :
path : *aio_preview_artifact_path
# The `destination` needs to be kept in synch with the value of
# `AIO_ARTIFACT_PATH` in `aio/aio-builds-setup/Dockerfile`
destination : aio/dist/aio-snapshot.tgz
2018-12-04 08:50:17 -05:00
- run : node ./aio/scripts/create-preview $CIRCLE_BUILD_NUM
2018-05-09 13:54:13 -04:00
2018-10-17 12:19:15 -04:00
# This job should only be run on PR builds, where `CI_PULL_REQUEST` is not `false`.
2018-08-25 17:40:58 -04:00
test_aio_preview :
<< : *job_defaults
2018-10-27 03:25:45 -04:00
docker :
# Needed because the test-preview script runs e2e tests and the PWA score test with Chrome.
- image : *browsers_docker_image
2018-08-25 17:40:58 -04:00
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-02-06 03:19:51 -05:00
- run : yarn --cwd aio install --frozen-lockfile --non-interactive
2018-08-25 17:40:58 -04:00
- run :
name : Wait for preview and run tests
2018-10-22 06:06:20 -04:00
command : node aio/scripts/test-preview.js $CI_PULL_REQUEST $CI_COMMIT $CI_AIO_MIN_PWA_SCORE
2018-08-25 17:40:58 -04:00
2019-01-14 20:47:39 -05:00
# The `build-npm-packages` tasks exist for backwards-compatibility with old scripts and
# tests that rely on the pre-Bazel `dist/packages-dist` output structure (build.sh).
# Having multiple jobs that independently build in this manner duplicates some work; we build
# the bazel packages more than once. Even though we have a remote cache, these jobs will
# typically run in parallel so up-to-date outputs will not be available at the time the build
2018-04-23 14:46:02 -04:00
# starts.
2019-01-14 20:47:39 -05:00
# Build the view engine npm packages. No new jobs should depend on this.
build-npm-packages :
2018-04-23 14:46:02 -04:00
<< : *job_defaults
resource_class : xlarge
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-02-05 15:21:03 -05:00
- *setup_circleci_bazel_config
2018-08-02 00:02:36 -04:00
- *setup_bazel_remote_execution
2018-10-27 03:25:45 -04:00
2018-08-02 00:02:36 -04:00
- run : scripts/build-packages-dist.sh
2018-04-23 14:46:02 -04:00
# Save the npm packages from //packages/... for other workflow jobs to read
- persist_to_workspace :
2019-02-25 04:19:07 -05:00
root : ~/
2018-04-23 14:46:02 -04:00
paths :
2019-02-25 04:19:07 -05:00
- ng/dist/packages-dist
2019-01-14 20:47:39 -05:00
2019-02-25 04:19:07 -05:00
# Save dependencies and bazel repository cache to use on subsequent runs.
2019-02-06 03:26:36 -05:00
- save_cache :
key : *cache_key
paths :
- "node_modules"
2019-02-22 12:30:19 -05:00
- "aio/node_modules"
2019-02-06 03:26:36 -05:00
- "~/bazel_repository_cache"
2019-01-14 20:47:39 -05:00
# Build the ivy npm packages.
build-ivy-npm-packages :
<< : *job_defaults
resource_class : xlarge
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-02-05 15:21:03 -05:00
- *setup_circleci_bazel_config
2019-01-14 20:47:39 -05:00
- *setup_bazel_remote_execution
- run : scripts/build-ivy-npm-packages.sh
# Save the npm packages from //packages/... for other workflow jobs to read
- persist_to_workspace :
2019-02-25 04:19:07 -05:00
root : ~/
2019-01-14 20:47:39 -05:00
paths :
2019-02-25 04:19:07 -05:00
- ng/dist/packages-dist-ivy-aot
2018-04-23 14:46:02 -04:00
# We run the integration tests outside of Bazel for now.
# They are a separate workflow job so that they can be easily re-run.
# When the tests are ported to bazel test targets, they should move to the "test"
# job above, as part of the bazel test command. That has flaky_test_attempts so the
# need to re-run manually should be alleviated.
# See comments inside the integration/run_tests.sh script.
integration_test :
<< : *job_defaults
2019-01-06 06:37:46 -05:00
parallelism : 4
2018-10-27 03:25:45 -04:00
docker :
# Needed because the integration tests expect Chrome to be installed (e.g cli-hello-world)
- image : *browsers_docker_image
2018-06-14 10:37:06 -04:00
# Note: we run Bazel in one of the integration tests, and it can consume >2G
# of memory. Together with the system under test, this can exhaust the RAM
# on a 4G worker so we use a larger machine here too.
resource_class : xlarge
2018-04-23 14:46:02 -04:00
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-01-06 06:37:46 -05:00
# Runs the integration tests in parallel across multiple CircleCI container instances. The
# amount of container nodes for this job is controlled by the "parallelism" option.
- run : ./integration/run_tests.sh ${CIRCLE_NODE_INDEX} ${CIRCLE_NODE_TOTAL}
2018-04-23 14:46:02 -04:00
# This job updates the content of repos like github.com/angular/core-builds
# for every green build on angular/angular.
publish_snapshot :
<< : *job_defaults
steps :
2018-04-27 19:21:38 -04:00
# See below - ideally this job should not trigger for non-upstream builds.
# But since it does, we have to check this condition.
- run :
name : Skip this job for Pull Requests and Fork builds
2019-02-28 10:23:54 -05:00
# Note: Using `CIRCLE_*` env variables (instead of those defined in `env.sh` so that this
# step can be run before `init_environment`.
command : >
if [[ -n "${CIRCLE_PR_NUMBER}" ]] ||
[ [ "$CIRCLE_PROJECT_USERNAME" != "angular" ]] ||
[ [ "$CIRCLE_PROJECT_REPONAME" != "angular" ]]; then
circleci step halt
fi
- *attach_workspace
- *init_environment
2018-04-23 14:46:02 -04:00
# CircleCI has a config setting to force SSH for all github connections
# This is not compatible with our mechanism of using a Personal Access Token
# Clear the global setting
- run : git config --global --unset "url.ssh://git@github.com.insteadof"
2018-04-27 19:21:38 -04:00
- run :
name : Decrypt github credentials
2019-06-17 16:37:27 -04:00
# We need ensure that the same default digest is used for encoding and decoding with
# openssl. Openssl versions might have different default digests which can cause
# decryption failures based on the installed openssl version. https://stackoverflow.com/a/39641378/4317734
command : 'openssl aes-256-cbc -d -in .circleci/github_token -md md5 -k "${KEY}" -out ~/.git_credentials'
2018-04-23 14:46:02 -04:00
- run : ./scripts/ci/publish-build-artifacts.sh
2019-04-25 06:54:10 -04:00
aio_monitoring_stable :
2018-02-27 18:24:07 -05:00
<< : *job_defaults
2018-10-27 03:25:45 -04:00
docker :
# This job needs Chrome to be globally installed because the tests run with Protractor
# which does not load the browser through the Bazel webtesting rules.
- image : *browsers_docker_image
2018-02-27 18:24:07 -05:00
steps :
2019-04-25 06:41:46 -04:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-04-25 06:59:16 -04:00
- run : setPublicVar_CI_STABLE_BRANCH
- run :
name : Check out `aio/` from the stable branch
command : |
git fetch origin $CI_STABLE_BRANCH
git checkout --force origin/$CI_STABLE_BRANCH -- aio/
2018-09-27 09:35:05 -04:00
- run :
2019-04-25 06:54:10 -04:00
name : Run tests against https://angular.io/
command : ./aio/scripts/test-production.sh https://angular.io/ $CI_AIO_MIN_PWA_SCORE
2019-06-21 17:45:19 -04:00
- *notify_caretaker_on_fail
- *notify_dev_infra_on_fail
2019-04-25 06:54:10 -04:00
aio_monitoring_next :
<< : *job_defaults
docker :
# This job needs Chrome to be globally installed because the tests run with Protractor
# which does not load the browser through the Bazel webtesting rules.
- image : *browsers_docker_image
steps :
- *attach_workspace
- *init_environment
- run :
name : Run tests against https://next.angular.io/
command : ./aio/scripts/test-production.sh https://next.angular.io/ $CI_AIO_MIN_PWA_SCORE
2019-06-21 17:45:19 -04:00
- *notify_caretaker_on_fail
- *notify_dev_infra_on_fail
2018-02-27 18:24:07 -05:00
2019-01-04 14:58:33 -05:00
legacy-unit-tests-saucelabs :
<< : *job_defaults
# In order to avoid the bottleneck of having a slow host machine, we acquire a better
# container for this job. This is necessary because we launch a lot of browsers concurrently
# and therefore the tunnel and Karma need to process a lot of file requests and tests.
resource_class : xlarge
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-01-04 14:58:33 -05:00
- run :
name : Preparing environment for running tests on Saucelabs.
command : |
setPublicVar KARMA_JS_BROWSERS $(node -e 'console.log(require("./browser-providers.conf").sauceAliases.CI_REQUIRED.join(","))')
setSecretVar SAUCE_ACCESS_KEY $(echo $SAUCE_ACCESS_KEY | rev)
- run :
name : Starting Saucelabs tunnel
command : ./scripts/saucelabs/start-tunnel.sh
background : true
- run : yarn tsc -p packages
- run : yarn tsc -p modules
# Waits for the Saucelabs tunnel to be ready. This ensures that we don't run tests
# too early without Saucelabs not being ready.
- run : ./scripts/saucelabs/wait-for-tunnel.sh
- run : yarn karma start ./karma-js.conf.js --single-run --browsers=${KARMA_JS_BROWSERS}
- run : ./scripts/saucelabs/stop-tunnel.sh
2019-01-05 08:01:47 -05:00
legacy-misc-tests :
<< : *job_defaults
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
2019-01-05 08:01:47 -05:00
- run : yarn gulp check-cycle
# TODO: disabled because the Bazel packages-dist does not seem to have map files for
# the ESM5/ES2015 output. See: https://github.com/angular/angular/issues/27966
# - run: yarn gulp source-map-test
2019-01-04 14:58:33 -05:00
2019-01-14 20:47:39 -05:00
# Job to run unit tests from angular/material2. Needs a browser since all
# component unit tests assume they're running in the browser environment.
material-unit-tests :
<< : *job_defaults
resource_class : xlarge
docker :
- image : *browsers_docker_image
steps :
2019-02-25 04:19:07 -05:00
- *attach_workspace
2019-02-17 13:38:37 -05:00
- *init_environment
test(ivy): update Material to recent commit from master branch (#31569)
Previously, the ivy-2019 branch of the Material (aka components) repo was
used, which contains some changes that were necessary to work with Ivy.
These changes are not longer necessary, as Material's master branch is
fully working with Ivy today. To be up-to-date with recent Material
development and its support for more recent dependencies, e.g. TypeScript,
it is desirable for us to be on a newer version of Material.
This commit moves the Material tests away from the ivy-2019 branch, to a
recent commit on master. We are not targeting the master branch itself,
as that would introduce a moving target into Angular's CI checks, which
is undesirable.
Lastly, the usage of gulp to run Material's tests is changed into using
Bazel, as Material itself is now also built with Bazel.
PR Close #31569
2019-06-13 15:06:14 -04:00
# Although RBE is configured below for the Material repo, also setup RBE in the Angular repo
# to provision Angular's GCP token into the environment variables.
- *setup_bazel_remote_execution
2019-07-23 16:54:56 -04:00
# Restore the cache before cloning the repository because the clone script re-uses
# the restored repository if present. This reduces the amount of times the components
# repository needs to be cloned (this is slow and increases based on commits in the repo).
2019-03-18 14:25:19 -04:00
- restore_cache :
keys :
2019-07-23 16:54:56 -04:00
- *material_unit_tests_cache_key
- *material_unit_tests_cache_key_short
- run :
name : "Fetching Material repository"
command : ./scripts/ci/clone_angular_material_repo.sh
2019-03-18 14:25:19 -04:00
- run :
2019-07-23 16:54:56 -04:00
# Run yarn install to fetch the Bazel binaries as used in the Material repo.
2019-03-20 07:43:20 -04:00
name : Installing Material dependencies.
command : yarn --cwd ${MATERIAL_REPO_TMP_DIR} install --frozen-lockfile --non-interactive
2019-03-18 14:25:19 -04:00
- save_cache :
2019-07-23 16:54:56 -04:00
key : *material_unit_tests_cache_key
2019-03-18 14:25:19 -04:00
paths :
2019-07-23 16:54:56 -04:00
# Material directory must be kept in sync with the `$MATERIAL_REPO_TMP_DIR` env variable.
# It needs to be hardcoded here, because env variables interpolation is not supported.
- "/tmp/material2"
test(ivy): update Material to recent commit from master branch (#31569)
Previously, the ivy-2019 branch of the Material (aka components) repo was
used, which contains some changes that were necessary to work with Ivy.
These changes are not longer necessary, as Material's master branch is
fully working with Ivy today. To be up-to-date with recent Material
development and its support for more recent dependencies, e.g. TypeScript,
it is desirable for us to be on a newer version of Material.
This commit moves the Material tests away from the ivy-2019 branch, to a
recent commit on master. We are not targeting the master branch itself,
as that would introduce a moving target into Angular's CI checks, which
is undesirable.
Lastly, the usage of gulp to run Material's tests is changed into using
Bazel, as Material itself is now also built with Bazel.
PR Close #31569
2019-06-13 15:06:14 -04:00
- run :
name : "Setup Bazel RBE remote execution in Material repo"
command : |
./.circleci/setup-rbe.sh "${MATERIAL_REPO_TMP_DIR}/.bazelrc.user"
2019-03-20 07:43:20 -04:00
- run :
name : "Running Material unit tests"
command : ./scripts/ci/run_angular_material_unit_tests.sh
2019-01-14 20:47:39 -05:00
2019-05-31 11:56:07 -04:00
test_zonejs :
<< : *job_defaults
steps :
- *attach_workspace
- *init_environment
# Install
- run : yarn --cwd packages/zone.js install --frozen-lockfile --non-interactive
# Run zone.js tools tests
- run : yarn --cwd packages/zone.js promisetest
- run : yarn --cwd packages/zone.js promisefinallytest
2019-07-18 12:42:23 -04:00
- run : yarn bazel build //packages/zone.js:npm_package &&
cp dist/bin/packages/zone.js/npm_package/dist/zone-mix.js ./packages/zone.js/test/extra/ &&
cp dist/bin/packages/zone.js/npm_package/dist/zone-patch-electron.js ./packages/zone.js/test/extra/ &&
yarn --cwd packages/zone.js electrontest
2019-05-31 11:56:07 -04:00
2019-07-25 10:47:02 -04:00
# Windows jobs
# Docs: https://circleci.com/docs/2.0/hello-world-windows/
# Skipping workspace for now because it fails to extract on windows.
# TODO: when CircleCI fixes it, split this single job into install/test ones.
# Notes:
# - windows needs its own cache key because binaries in node_modules are different.
# - windows might need its own workspace for the same reason.
test_win :
<< : *job_defaults_win
steps :
- checkout
- *init_environment_win
- *post_checkout_win
# TODO: windows cache restoration is currently failing. Re-enable when it's fixed.
# Example failure: https://circleci.com/gh/angular/angular/423738
# - *restore_cache_win
- *setup_circleci_bazel_config_win
- run : yarn install --frozen-lockfile --non-interactive
# Install @bazel/bazel globally and use that for the first run.
# Workaround for https://github.com/bazelbuild/rules_nodejs/issues/894
- run : yarn global add @bazel/bazel@$env:BAZEL_VERSION
- run : bazel info
# Ran into a command parsing problem where `-browser:chromium-local` was converted to
# `-browser: chromium-local` (a space was added) in https://circleci.com/gh/angular/angular/357511.
# Probably a powershell command parsing thing. This way there's no problem.
- run :
command : yarn circleci-win-ve
no_output_timeout : 45m
# - save_cache:
# key: *cache_key_win
# paths:
# - "node_modules"
# - "C:/Users/circleci/bazel_repository_cache"
test_ivy_aot_win :
<< : *job_defaults_win
steps :
- checkout
- *init_environment_win
- *post_checkout_win
# - *restore_cache_win
- *setup_circleci_bazel_config_win
- run : yarn install --frozen-lockfile --non-interactive
- run : yarn global add @bazel/bazel@$env:BAZEL_VERSION
- run : bazel info
- run :
command : yarn circleci-win-ivy
no_output_timeout : 45m
2017-06-14 19:38:27 -04:00
workflows :
version : 2
default_workflow :
jobs :
2019-08-19 20:52:25 -04:00
- setup :
filters :
branches :
ignore : g3
2019-02-22 12:30:19 -05:00
- lint :
requires :
2019-07-18 16:33:45 -04:00
- setup
2019-02-22 12:30:19 -05:00
- test :
requires :
2019-07-18 16:33:45 -04:00
- setup
2019-02-22 12:30:19 -05:00
- test_ivy_aot :
requires :
2019-07-18 16:33:45 -04:00
- setup
2019-02-22 12:30:19 -05:00
- build-npm-packages :
requires :
2019-07-18 16:33:45 -04:00
- setup
2019-02-22 12:30:19 -05:00
- build-ivy-npm-packages :
requires :
2019-07-18 16:33:45 -04:00
- setup
- legacy-misc-tests :
2019-02-22 12:30:19 -05:00
requires :
2019-07-18 16:33:45 -04:00
- build-npm-packages
2019-03-12 14:44:03 -04:00
- legacy-unit-tests-saucelabs :
requires :
2019-07-18 16:33:45 -04:00
- setup
2019-07-18 16:33:52 -04:00
- test_saucelabs_bazel :
requires :
- setup
2019-07-19 06:35:22 -04:00
# This job is currently a PoC and a subset of `legacy-unit-tests-saucelabs`. Running on
# master only to avoid wasting resources.
#
# TODO: Run this job on all branches (including PRs) as soon as it is not a PoC.
2019-07-18 16:33:52 -04:00
filters :
branches :
only : master
2019-07-18 16:33:45 -04:00
- test_aio :
requires :
- setup
2018-10-25 07:01:24 -04:00
- deploy_aio :
requires :
- test_aio
2018-10-10 16:55:45 -04:00
- test_aio_local :
requires :
2019-01-14 20:47:39 -05:00
- build-npm-packages
2018-11-05 12:21:27 -05:00
- test_aio_local_ivy :
requires :
2019-04-02 14:53:49 -04:00
- build-npm-packages
2018-10-10 16:55:45 -04:00
- test_aio_tools :
requires :
2019-01-14 20:47:39 -05:00
- build-npm-packages
2019-01-06 09:37:55 -05:00
- test_docs_examples :
2018-10-10 16:55:45 -04:00
requires :
2019-01-14 20:47:39 -05:00
- build-npm-packages
2019-02-05 16:20:05 -05:00
- test_docs_examples_ivy :
requires :
2019-02-26 14:17:25 -05:00
- build-ivy-npm-packages
2018-09-20 04:21:53 -04:00
- aio_preview :
2019-02-22 12:30:19 -05:00
requires :
2019-02-22 16:33:53 -05:00
- setup
2018-09-20 04:21:53 -04:00
# Only run on PR builds. (There can be no previews for non-PR builds.)
filters :
branches :
only : /pull\/\d+/
2018-08-25 17:40:58 -04:00
- test_aio_preview :
requires :
- aio_preview
2018-04-23 14:46:02 -04:00
- integration_test :
requires :
2019-01-14 20:47:39 -05:00
- build-npm-packages
2018-04-23 14:46:02 -04:00
- publish_snapshot :
# Note: no filters on this job because we want it to run for all upstream branches
# We'd really like to filter out pull requests here, but not yet available:
# https://discuss.circleci.com/t/workflows-pull-request-filter/14396/4
2018-04-27 19:21:38 -04:00
# Instead, the job just exits immediately at the first step.
2018-04-23 14:46:02 -04:00
requires :
2018-04-23 19:41:10 -04:00
# Only publish if tests and integration tests pass
2018-04-23 19:14:34 -04:00
- test
2018-06-05 14:38:46 -04:00
- test_ivy_aot
2018-04-23 19:41:10 -04:00
- integration_test
2018-10-24 09:51:00 -04:00
# Only publish if `aio`/`docs` tests using the locally built Angular packages pass
- test_aio_local
2018-11-05 12:21:27 -05:00
- test_aio_local_ivy
2019-01-06 09:37:55 -05:00
- test_docs_examples
2019-02-05 16:20:05 -05:00
- test_docs_examples_ivy
# Get the artifacts to publish from the build-packages-dist job
2018-04-23 19:14:34 -04:00
# since the publishing script expects the legacy outputs layout.
2019-01-14 20:47:39 -05:00
- build-npm-packages
- build-ivy-npm-packages
2019-03-12 14:44:03 -04:00
- legacy-unit-tests-saucelabs
2019-01-05 08:01:47 -05:00
- legacy-misc-tests
2019-01-14 20:47:39 -05:00
- material-unit-tests :
requires :
- build-ivy-npm-packages
2019-05-31 11:56:07 -04:00
- test_zonejs :
requires :
- setup
2019-07-25 10:47:02 -04:00
# Windows jobs very slow so we run it on non-PRs only for now.
# TODO: remove the filter when CircleCI makes Windows FS faster.
# The Windows jobs are only run after their non-windows counterparts finish successfully.
# This isn't strictly necessary as there is no artifact dependency, but helps economize
# CI resources by not attempting to build when we know should fail.
- test_win :
requires :
- test
filters :
branches :
ignore :
- /pull\/.*/
- test_ivy_aot_win :
requires :
- test_ivy_aot
filters :
branches :
ignore :
- /pull\/.*/
2019-01-04 14:58:33 -05:00
2019-04-27 05:56:34 -04:00
aio_monitoring :
jobs :
- setup
- aio_monitoring_stable :
requires :
- setup
- aio_monitoring_next :
requires :
- setup
triggers :
- schedule :
# Runs AIO monitoring jobs at 10:00AM every day.
cron : "0 10 * * *"
filters :
branches :
only :
- master