diff --git a/.github/workflows/orca.yml b/.github/workflows/orca.yml index 39f0abb4d..40488346a 100644 --- a/.github/workflows/orca.yml +++ b/.github/workflows/orca.yml @@ -141,15 +141,17 @@ jobs: run: | ../orca/bin/ci/self-test/before_install.sh ../orca/bin/ci/before_install.sh - # D11 requires yarn>=4.1.1 - npm cache clean --force - # Remove the previous yarn installed in the container. - npm uninstall -g yarn - npm install -g corepack - corepack enable - yarn set version 4.1.1 - yarn -v - + if [[ "$ORCA_ENABLE_NIGHTWATCH" == "TRUE" && "$ORCA_SUT_HAS_NIGHTWATCH_TESTS" && -d "$ORCA_YARN_DIR" ]]; then + # Install yarn 4.1.1. + cd "$ORCA_YARN_DIR" || exit + npm cache clean --force + # Remove the previous yarn installed in the container. + npm uninstall -g yarn + npm install -g corepack + corepack enable + yarn set version 4.1.1 + yarn -v + fi - name: Install run: |