diff --git a/.circleci/config.yml b/.circleci/config.yml index 2d365226b..da1dc9970 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -107,70 +107,6 @@ jobs: environment: CHROMIUM_BIN: '/usr/bin/google-chrome' - bazel-build: - <<: *job_defaults - resource_class: large - steps: - - checkout - - restore_cache: - key: *cache_key - - *yarn_install - - run: - command: yarn bazel build //... - environment: - # TODO: Remove when pnpm is exclusively used. - ASPECT_RULES_JS_FROZEN_PNPM_LOCK: '1' - - *save_cache - - bazel-test: - <<: *job_defaults - resource_class: large - steps: - - checkout - - restore_cache: - key: *cache_key - - *yarn_install - - run: - command: yarn bazel test --test_tag_filters=-lint,-e2e,-audit //... - environment: - # TODO: Remove when pnpm is exclusively used. - ASPECT_RULES_JS_FROZEN_PNPM_LOCK: '1' - - *save_cache - - store_artifacts: - path: bazel-testlogs/ - - store_artifacts: - path: bazel-testlogs/scenes/ - - bazel-lint: - <<: *job_defaults - resource_class: large - steps: - - checkout - - restore_cache: - key: *cache_key - - *yarn_install - - run: yarn bazel test --test_tag_filters=+lint //... - - *save_cache - - store_artifacts: - path: bazel-testlogs/ - - store_artifacts: - path: bazel-testlogs/scenes/ - - bazel-lighthouse_audits: - <<: *job_defaults - resource_class: xlarge - steps: - - checkout - - restore_cache: - key: *cache_key - - *yarn_install - - run: yarn bazel test --test_tag_filters=+audit //... - - *save_cache - - store_artifacts: - path: bazel-testlogs/ - - store_artifacts: - path: bazel-testlogs/scenes/ - workflows: version: 2 default_workflow: @@ -181,7 +117,3 @@ workflows: - lighthouse_audits: requires: - build - - bazel-build - - bazel-test - - bazel-lighthouse_audits - - bazel-lint diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml new file mode 100644 index 000000000..e4a8eb6d5 --- /dev/null +++ b/.github/workflows/pr.yml @@ -0,0 +1,72 @@ +name: Pull Request + +on: + pull_request: + types: [opened, synchronize, reopened] + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +permissions: {} + +defaults: + run: + shell: bash + +env: + # TODO: Remove when pnpm is exclusively used. + ASPECT_RULES_JS_FROZEN_PNPM_LOCK: '1' + +jobs: + lint: + runs-on: ubuntu-latest + steps: + - name: Initialize environment + uses: angular/dev-infra/github-actions/npm/checkout-and-setup-node@db91da4e742cd081bfba01db2edc4e816018419b + - name: Install node modules + run: yarn install + - name: Execute Linting + run: yarn bazel test --test_tag_filters=lint //... + + build: + runs-on: ubuntu-latest + steps: + - name: Initialize environment + uses: angular/dev-infra/github-actions/npm/checkout-and-setup-node@db91da4e742cd081bfba01db2edc4e816018419b + - name: Install node modules + run: yarn install + - name: Execute Build + run: yarn bazel build //... + + test: + runs-on: ubuntu-latest + steps: + - name: Initialize environment + uses: angular/dev-infra/github-actions/npm/checkout-and-setup-node@db91da4e742cd081bfba01db2edc4e816018419b + - name: Install node modules + run: yarn install + - name: Execute Tests + run: yarn bazel test --test_tag_filters=-lint,-e2e,-audit //... + - name: Store Test Logs + uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4.3.6 + with: + name: test-logs + path: bazel-testlogs/ + retention-days: 14 + + lighthouse: + runs-on: ubuntu-latest + steps: + - name: Initialize environment + uses: angular/dev-infra/github-actions/npm/checkout-and-setup-node@db91da4e742cd081bfba01db2edc4e816018419b + - name: Install node modules + run: yarn install + - name: Execute Lighthouse Audit + run: yarn bazel test --test_tag_filters=audit //... + - name: Store Audit Logs + uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4.3.6 + with: + name: lighthouse-logs + path: bazel-testlogs/ + retention-days: 14 diff --git a/.nvmrc b/.nvmrc index 8b0beab16..8ce703082 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -20.11.0 +20.16.0