Skip to content

Commit

Permalink
Fix angular-bazel-example test in CI which was crashing and flaking o…
Browse files Browse the repository at this point in the history
…ut (#792)

`bazel test //e2e:all` was crashing before the tests even started in CI. Possibly out of memory but not sure how that is possible as it was running in the xlarge 16GB container. This PR moves the angular-bazel-example test to its own CI job (which speeds up overall CI time as its critical path) and runs the same CI tests that angular-bazel-example runs in its own CI.
  • Loading branch information
gregmagolan authored May 24, 2019
1 parent f96a06b commit 5cc5c06
Showing 1 changed file with 34 additions and 1 deletion.
35 changes: 34 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -299,10 +299,36 @@ jobs:
- *attach_workspace
- *init_environment
- *init_bazel
- run: ./scripts/setup_examples_angular.sh
# Some examples such as app require xvfb
- run: xvfb-run -a ./scripts/test_examples_all.sh ${CIRCLE_NODE_INDEX} ${CIRCLE_NODE_TOTAL}

# This job cannot run on BuildKite (BazelCI) because it requires changing
# directories to test inside nested workspaces.
# See https://github.com/bazelbuild/continuous-integration/issues/225
test_angular_bazel_example:
<<: *job_defaults
docker:
# Needed because some tests require local chrome
- image: *browsers_docker_image
resource_class: xlarge
steps:
- *attach_workspace
- *init_environment
- *init_bazel
- run: ./scripts/setup_examples_angular.sh
- run:
name: Test angular-bazel-example
command: |
cd ./examples/angular
../../scripts/link_deps.sh
# Install Bazel from NPM
yarn
# Build and Test
yarn ng test
yarn ng e2e
# Also run prodserver test which is not covered by `ng e2e`
yarn bazel test //e2e:prodserver_test
workflows:
version: 2
default_workflow:
Expand Down Expand Up @@ -356,3 +382,10 @@ workflows:
- build_jasmine_package
- build_labs_package
- build_karma_package
- test_angular_bazel_example:
requires:
- build_release
- build_typescript_package
- build_jasmine_package
- build_labs_package
- build_karma_package

0 comments on commit 5cc5c06

Please sign in to comment.