diff --git a/taskcluster/ci/tests/kind.yml b/taskcluster/ci/tests/kind.yml index 025aeaaf..c3a19825 100644 --- a/taskcluster/ci/tests/kind.yml +++ b/taskcluster/ci/tests/kind.yml @@ -37,6 +37,10 @@ jobs: description: "Run `unit tests` to validate the latest changes" treeherder: symbol: unit + worker: + env: + # fail instead of skipping tests due to missing information + NO_TEST_SKIP: 1 run: command: [python, setup.py, test] flake8: diff --git a/tcadmin/tests/test_util_scopes.py b/tcadmin/tests/test_util_scopes.py index da755408..f97c0dd9 100644 --- a/tcadmin/tests/test_util_scopes.py +++ b/tcadmin/tests/test_util_scopes.py @@ -6,6 +6,7 @@ import pytest import taskcluster +import os from tcadmin.util.scopes import Resolver, satisfies from tcadmin.resources import Role, Resources @@ -225,6 +226,14 @@ def test_normalizeScopes_with_stars(): @pytest.fixture(scope="module") def auth(): + # tests using this fixture need *some* auth service, but it actually + # doesn't matter which one + if "TASKCLUSTER_ROOT_URL" not in os.environ: + msg = "TASKCLUSTER_ROOT_URL not set" + if "NO_TEST_SKIP" in os.environ: + pytest.fail(msg) + else: + pytest.skip(msg) return taskcluster.Auth(taskcluster.optionsFromEnvironment())