@@ -117,12 +117,6 @@ var_17: &setup_bazel_binary
117117 name : " Setting up global Bazel binary"
118118 command : ./scripts/circleci/setup_bazel_binary.sh
119119
120- # **Note**: When updating the beginning of the cache key, also update the fallback cache
121- # key to match the new cache key prefix. This allows us to take advantage of CircleCI's
122- # fallback caching. Read more here: https://circleci.com/docs/2.0/caching/#restoring-cache.
123- var_18 : &mdc_deps_cache_key v1-mdc-deps-{{ checksum "/tmp/material-components-web/package-lock.json" }}
124- var_19 : &mdc_deps_fallback_cache_key v1-mdc-deps-
125-
126120# -----------------------------
127121# Container version of CircleCI
128122# -----------------------------
@@ -430,16 +424,13 @@ jobs:
430424 - run : bazel test src/... --build_tag_filters=-docs-package,-e2e --test_tag_filters=-e2e --config=view-engine
431425
432426 # ----------------------------------------------------------------------------
433- # Job that runs all Bazel tests against material-components-web#master.
427+ # Job that runs all Bazel tests against material-components-web@canary
434428 # ----------------------------------------------------------------------------
435429 mdc_snapshot_test_cronjob :
436430 << : *job_defaults
437431 resource_class : xlarge
438432 environment :
439433 GCP_DECRYPT_TOKEN : *gcp_decrypt_token
440- MDC_REPO_URL : " https://github.com/material-components/material-components-web.git"
441- MDC_REPO_BRANCH : " master"
442- MDC_REPO_TMP_DIR : " /tmp/material-components-web"
443434 steps :
444435 - *checkout_code
445436 - *restore_cache
@@ -449,30 +440,11 @@ jobs:
449440 - *yarn_download
450441 - *yarn_install
451442
452- - run : git clone ${MDC_REPO_URL} --branch ${MDC_REPO_BRANCH} --depth 1 ${MDC_REPO_TMP_DIR}
453- - restore_cache :
454- keys :
455- - *mdc_deps_cache_key
456- - *mdc_deps_fallback_cache_key
457- - run :
458- name : " Installing dependencies for MDC repository"
459- # MDC repository does not use Yarn for node dependencies, so in order to respect the
460- # lock-file we need to use "npm" when installing dependencies.
461- command : cd ${MDC_REPO_TMP_DIR} && npm install
462- - save_cache :
463- key : *mdc_deps_cache_key
464- paths :
465- # Repository path must be kept in sync with the `$MDC_REPO_TMP_DIR` env variable.
466- # It needs to be hardcoded here, because env variables interpolation is not supported.
467- - " /tmp/material-components-web/node_modules"
468- - run :
469- name : " Building MDC snapshot builds"
470- command : |
471- cd ${MDC_REPO_TMP_DIR}
472- yarn dist && node scripts/cp-pkgs.js
443+ # Install the latest canary version of the "material-components-web".
444+ - run : yarn add material-components-web@canary
445+
473446 # Setup the components repository to use the MDC snapshot builds.
474- - run : node ./scripts/circleci/setup-mdc-snapshots.js ${MDC_REPO_TMP_DIR}/packages/ $(git -C ${MDC_REPO_TMP_DIR} rev-parse HEAD)
475- # Run project tests with the MDC snapshot builds.
447+ # Run project tests with the MDC canary builds.
476448 - run : bazel build src/... --build_tag_filters=-docs-package,-e2e
477449 - run : bazel test src/... --build_tag_filters=-docs-package,-e2e --test_tag_filters=-e2e
478450
0 commit comments