From a52aee2bb369790b6158e07a844c8bbaaa1dbb6e Mon Sep 17 00:00:00 2001 From: jj Date: Tue, 18 Feb 2025 09:12:55 +0000 Subject: [PATCH] ci: use TEST_IGNORE_SERVICES variable for ignoring services --- .github/workflows/test-services.yml | 2 +- api/src/util/test.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test-services.yml b/.github/workflows/test-services.yml index 993fbcb4..ad6e25b7 100644 --- a/.github/workflows/test-services.yml +++ b/.github/workflows/test-services.yml @@ -33,4 +33,4 @@ jobs: - run: pnpm i --frozen-lockfile && node api/src/util/test run-tests-for ${{ matrix.service }} env: API_EXTERNAL_PROXY: ${{ secrets.API_EXTERNAL_PROXY }} - TEST_IGNORE_SERVICES: "none" + TEST_IGNORE_SERVICES: ${{ vars.TEST_IGNORE_SERVICES }} diff --git a/api/src/util/test.js b/api/src/util/test.js index a11130a7..abb9b3cd 100644 --- a/api/src/util/test.js +++ b/api/src/util/test.js @@ -15,7 +15,7 @@ const getTests = (service) => loadJSON(getTestPath(service)); // services that are known to frequently fail due to external // factors (e.g. rate limiting) const finnicky = new Set( - typeof process.env.TEST_IGNORE_SERVICES === 'string' + process.env.TEST_IGNORE_SERVICES ? process.env.TEST_IGNORE_SERVICES.split(',') : ['bilibili', 'instagram', 'facebook', 'youtube', 'vk', 'twitter', 'reddit'] );