diff --git a/bot/code_coverage_bot/artifacts.py b/bot/code_coverage_bot/artifacts.py index 476b7ca04..51019cbef 100644 --- a/bot/code_coverage_bot/artifacts.py +++ b/bot/code_coverage_bot/artifacts.py @@ -60,8 +60,8 @@ def get(self, platform=None, suite=None, chunk=None): return filtered_files def download(self, test_task): - chunk_name = taskcluster.get_chunk(test_task["task"]["metadata"]["name"]) - platform_name = taskcluster.get_platform(test_task["task"]["metadata"]["name"]) + chunk_name = taskcluster.get_chunk(test_task["task"]) + platform_name = taskcluster.get_platform(test_task["task"]) test_task_id = test_task["status"]["taskId"] for artifact in taskcluster.get_task_artifacts(test_task_id): @@ -104,7 +104,8 @@ def download_all(self): task for group in groups for task in taskcluster.get_tasks_in_group(group) - if taskcluster.is_coverage_task(task) and not self.is_filtered_task(task) + if taskcluster.is_coverage_task(task["task"]) + and not self.is_filtered_task(task) ] logger.info("Downloading artifacts from {} tasks".format(len(test_tasks))) @@ -130,10 +131,8 @@ def download_all(self): status ) - chunk_name = taskcluster.get_chunk(test_task["task"]["metadata"]["name"]) - platform_name = taskcluster.get_platform( - test_task["task"]["metadata"]["name"] - ) + chunk_name = taskcluster.get_chunk(test_task["task"]) + platform_name = taskcluster.get_platform(test_task["task"]) if any(to_ignore in chunk_name for to_ignore in SUITES_TO_IGNORE): continue diff --git a/bot/code_coverage_bot/chunk_mapping.py b/bot/code_coverage_bot/chunk_mapping.py index 2c28f48e0..040d93c52 100644 --- a/bot/code_coverage_bot/chunk_mapping.py +++ b/bot/code_coverage_bot/chunk_mapping.py @@ -62,6 +62,8 @@ def get_tests_chunks(revision, platform, suite): run_key_prefix = "test-linux64-ccov" elif platform == "windows": run_key_prefix = "test-windows10-64-ccov" + else: + raise Exception("Unsupported platform {}".format(platform)) r = requests.post( ACTIVEDATA_QUERY_URL, @@ -239,7 +241,7 @@ def _inner_generate( def chunk_test_iter(): test_iter = enumerate(tests_data["result.test"]) return ( - (platform, taskcluster.get_chunk(task_names[i]), test) + (platform, taskcluster.name_to_chunk(task_names[i]), test) for i, test in test_iter ) @@ -257,7 +259,7 @@ def chunk_test_iter(): (platform, chunk) = futures[future] files = future.result() - suite = taskcluster.get_suite(chunk) + suite = taskcluster.chunk_to_suite(chunk) if is_chunk_only_suite(suite): per_test_cursor.executemany( "INSERT INTO file_to_chunk VALUES (?,?,?)", diff --git a/bot/code_coverage_bot/taskcluster.py b/bot/code_coverage_bot/taskcluster.py index 7a57d6320..0c0b986d9 100644 --- a/bot/code_coverage_bot/taskcluster.py +++ b/bot/code_coverage_bot/taskcluster.py @@ -115,7 +115,6 @@ def perform_download(): "build-android-test-ccov/opt", ] - TEST_PLATFORMS = [ "test-linux64-ccov/debug", "test-windows10-64-ccov/debug", @@ -124,10 +123,16 @@ def perform_download(): def is_coverage_task(task): - return any(task["task"]["metadata"]["name"].startswith(t) for t in TEST_PLATFORMS) + return any(task["metadata"]["name"].startswith(t) for t in TEST_PLATFORMS) + +def name_to_chunk(name): + """ + Helper to convert a task name to a chunk + Used by chunk mapping + """ + assert isinstance(name, str) -def get_chunk(name): # Some tests are run on build machines, we define a placeholder chunk for those. if name in BUILD_PLATFORMS: return "build" @@ -139,18 +144,60 @@ def get_chunk(name): return "-".join([p for p in name.split("-") if p != "e10s"]) -def get_suite(chunk_name): - return "-".join([p for p in chunk_name.split("-") if not p.isdigit()]) +def chunk_to_suite(chunk): + """ + Helper to convert a chunk to a suite (no numbers) + Used by chunk mapping + """ + assert isinstance(chunk, str) + return "-".join([p for p in chunk.split("-") if not p.isdigit()]) + + +def get_chunk(task): + """ + Build clean chunk name from a Taskcluster task + """ + suite = get_suite(task) + chunks = task["extra"].get("chunks", {}) + if "current" in chunks: + return f'{suite}-{chunks["current"]}' + return suite + + +def get_suite(task): + """ + Build clean suite name from a Taskcluster task + """ + assert isinstance(task, dict) + tags = task["tags"] + extra = task["extra"] + treeherder = extra.get("treeherder", {}) + + if treeherder.get("jobKind") == "build": + return "build" + elif "suite" in extra: + if isinstance(extra["suite"], dict): + return extra["suite"]["name"] + return extra["suite"] + else: + return tags.get("test-type") + + raise Exception("Unknown chunk") -def get_platform(name): - if "linux" in name: - return "linux" - elif "win" in name: - return "windows" - elif "android-test" in name: - return "android-test" - elif "android-em" in name: - return "android-emulator" - else: +def get_platform(task): + """ + Build clean platform from a Taskcluster task + """ + assert isinstance(task, dict) + assert isinstance(task, dict) + tags = task.get("tags", {}) + platform = tags.get("os") + if not platform: raise Exception("Unknown platform") + + # Weird case for android build on Linux docker + if platform == "linux" and tags.get("android-stuff"): + return "android" + + return platform diff --git a/bot/tests/fixtures/build-android-test-ccov/opt.json b/bot/tests/fixtures/build-android-test-ccov/opt.json new file mode 100644 index 000000000..611161cf5 --- /dev/null +++ b/bot/tests/fixtures/build-android-test-ccov/opt.json @@ -0,0 +1,159 @@ +{ + "provisionerId": "aws-provisioner-v1", + "workerType": "gecko-3-b-android", + "schedulerId": "gecko-level-3", + "taskGroupId": "Mu6w3n-dS9GOfrv6wGOtvg", + "dependencies": [ + "CGQi0Z1nQhizLPmm9d3wYQ", + "L0gYcGJ1QgeMRebLMme27Q", + "RZMFIeVKTqekWYEP91wu8w", + "SDBWKWVPTC6SI4o4cNXn0w", + "fn4N8jQtRZWbuUAjlqXFLA", + "Mu6w3n-dS9GOfrv6wGOtvg" + ], + "requires": "all-completed", + "routes": [ + "index.gecko.v2.mozilla-central.latest.mobile.android-test-ccov", + "index.gecko.v2.mozilla-central.pushdate.2019.03.28.20190328173141.mobile.android-test-ccov", + "index.gecko.v2.mozilla-central.pushlog-id.35772.mobile.android-test-ccov", + "index.gecko.v2.mozilla-central.revision.e31357c7759379d2279b6883cb09c91997bfaa5d.mobile.android-test-ccov", + "index.gecko.v2.trunk.revision.e31357c7759379d2279b6883cb09c91997bfaa5d.mobile.android-test-ccov", + "tc-treeherder.v2.mozilla-central.e31357c7759379d2279b6883cb09c91997bfaa5d.35772" + ], + "priority": "medium", + "retries": 5, + "created": "2019-03-28T17:38:38.640Z", + "deadline": "2019-03-29T17:38:38.640Z", + "expires": "2020-03-27T17:38:38.640Z", + "scopes": [ + "queue:get-artifact:project/gecko/android-sdk/*", + "secrets:get:project/taskcluster/gecko/hgfingerprint", + "docker-worker:relengapi-proxy:tooltool.download.public", + "docker-worker:relengapi-proxy:tooltool.download.internal", + "secrets:get:project/releng/gecko/build/level-3/*", + "docker-worker:cache:gecko-level-3-mozilla-central-build-android-test-ccov-opt-workspace-v3-33ea6ead87f10b63cd64", + "docker-worker:cache:gecko-level-3-checkouts-v3-33ea6ead87f10b63cd64", + "docker-worker:cache:gecko-level-3-tooltool-cache-v3-33ea6ead87f10b63cd64" + ], + "payload": { + "onExitStatus": { + "retry": [ + 4, + 72 + ], + "purgeCaches": [ + 72 + ] + }, + "maxRunTime": 7200, + "image": { + "path": "public/image.tar.zst", + "type": "task-image", + "taskId": "fn4N8jQtRZWbuUAjlqXFLA" + }, + "cache": { + "gecko-level-3-tooltool-cache-v3-33ea6ead87f10b63cd64": "/builds/worker/tooltool-cache", + "gecko-level-3-checkouts-v3-33ea6ead87f10b63cd64": "/builds/worker/checkouts", + "gecko-level-3-mozilla-central-build-android-test-ccov-opt-workspace-v3-33ea6ead87f10b63cd64": "/builds/worker/workspace" + }, + "artifacts": { + "public/logs": { + "path": "/builds/worker/logs/", + "expires": "2020-03-27T17:38:38.640Z", + "type": "directory" + }, + "public/build": { + "path": "/builds/worker/artifacts/", + "expires": "2020-03-27T17:38:38.640Z", + "type": "directory" + }, + "public/code-coverage-grcov.zip": { + "path": "/builds/worker/workspace/build/src/obj-firefox/code-coverage-grcov.zip", + "expires": "2020-03-27T17:38:38.640Z", + "type": "file" + } + }, + "command": [ + "/builds/worker/bin/run-task", + "--gecko-checkout", + "/builds/worker/workspace/build/src", + "--", + "/builds/worker/workspace/build/src/taskcluster/scripts/builder/build-linux.sh" + ], + "env": { + "MOZ_AUTOMATION": "1", + "MOZ_SOURCE_CHANGESET": "e31357c7759379d2279b6883cb09c91997bfaa5d", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.xz\", \"extract\": true, \"task\": \"CGQi0Z1nQhizLPmm9d3wYQ\"}]", + "PERFHERDER_EXTRA_OPTIONS": "android-test-ccov", + "TOOLTOOL_CACHE": "/builds/worker/tooltool-cache", + "PYTHONUNBUFFERED": "1", + "MOZ_FETCHES_DIR": "/builds/worker/fetches", + "MOZHARNESS_SCRIPT": "mozharness/scripts/fx_desktop_build.py", + "MOZ_BUILD_DATE": "20190328173141", + "MH_BUILD_POOL": "taskcluster", + "HG_STORE_PATH": "/builds/worker/checkouts/hg-store", + "MH_CUSTOM_BUILD_VARIANT_CFG": "android-test-ccov", + "MOZHARNESS_ACTIONS": "get-secrets build", + "GECKO_PATH": "/builds/worker/workspace/build/src", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "EXTRA_MOZHARNESS_CONFIG": "{\"update_channel\": \"nightly\"}", + "SCCACHE_DISABLE": "1", + "MOZ_TOOLCHAINS": "public/build/android-gradle-dependencies.tar.xz@RZMFIeVKTqekWYEP91wu8w project/gecko/android-sdk/android-sdk-linux.tar.xz@L0gYcGJ1QgeMRebLMme27Q public/build/node.tar.xz@SDBWKWVPTC6SI4o4cNXn0w", + "MOZ_SOURCE_REPO": "https://hg.mozilla.org/mozilla-central", + "GECKO_HEAD_REV": "e31357c7759379d2279b6883cb09c91997bfaa5d", + "MH_BRANCH": "mozilla-central", + "MOZ_SCM_LEVEL": "3", + "GECKO_BASE_REPOSITORY": "https://hg.mozilla.org/mozilla-unified", + "NEED_XVFB": "false", + "MOZ_DISABLE_FULL_SYMBOLS": "1", + "TASKCLUSTER_CACHES": "/builds/worker/checkouts;/builds/worker/tooltool-cache;/builds/worker/workspace", + "GRADLE_USER_HOME": "/builds/worker/workspace/build/src/mobile/android/gradle/dotgradle-offline", + "TASKCLUSTER_VOLUMES": "/builds/worker/checkouts;/builds/worker/tooltool-cache;/builds/worker/workspace", + "MOZHARNESS_CONFIG": "builds/releng_base_android_64_builds.py" + }, + "features": { + "taskclusterProxy": true, + "relengAPIProxy": true, + "chainOfTrust": true + } + }, + "metadata": { + "owner": "opoprus@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/e31357c7759379d2279b6883cb09c91997bfaa5d/taskcluster/ci/build", + "description": "Android armv7 unit test coverage report ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=e31357c7759379d2279b6883cb09c91997bfaa5d))", + "name": "build-android-test-ccov/opt" + }, + "tags": { + "kind": "build", + "worker-implementation": "docker-worker", + "createdForUser": "opoprus@mozilla.com", + "label": "build-android-test-ccov/opt", + "os": "linux", + "android-stuff": "true" + }, + "extra": { + "index": { + "rank": 1553794301 + }, + "chainOfTrust": { + "inputs": { + "docker-image": "fn4N8jQtRZWbuUAjlqXFLA" + } + }, + "treeherder": { + "jobKind": "build", + "groupSymbol": "A", + "collection": { + "opt": true + }, + "machine": { + "platform": "android-4-0-armv7-api16" + }, + "groupName": "Android Gradle tests", + "tier": 1, + "symbol": "test-ccov" + }, + "treeherder-platform": "android-4-0-armv7-api16/opt", + "parent": "Mu6w3n-dS9GOfrv6wGOtvg" + } +} \ No newline at end of file diff --git a/bot/tests/fixtures/build-linux64-ccov/debug.json b/bot/tests/fixtures/build-linux64-ccov/debug.json new file mode 100644 index 000000000..5c88525de --- /dev/null +++ b/bot/tests/fixtures/build-linux64-ccov/debug.json @@ -0,0 +1,163 @@ +{ + "created": "2019-08-07T21:54:28.511Z", + "deadline": "2019-08-08T21:54:28.511Z", + "dependencies": [ + "Cs2T4_a0R8iH8ehZwDKkNg", + "Gk89DrymQw-mUJsTOKwiUQ", + "LFxhtjbxTg6AwyCP8Wk0Vw", + "T9HmXbrnT4y-fk7ikXyalw", + "WtlBHsaBQni-PcKdJD7FwQ", + "aRGv3xq8S2-B0iqD2A9zVA", + "bTuzhPGaRkObDO1CbPNpRA", + "cYYO3myCSG6HvQ5AU_59vA", + "eSvT_7mITMGkjllEwe2ZRw", + "PUZr6C8WR9Cmw3LeL9qotw" + ], + "expires": "2020-08-06T21:54:28.511Z", + "extra": { + "chainOfTrust": { + "inputs": { + "docker-image": "LFxhtjbxTg6AwyCP8Wk0Vw" + } + }, + "index": { + "rank": 0 + }, + "parent": "PUZr6C8WR9Cmw3LeL9qotw", + "treeherder": { + "collection": { + "debug": true + }, + "jobKind": "build", + "machine": { + "platform": "linux64-ccov" + }, + "symbol": "B", + "tier": 2 + }, + "treeherder-platform": "linux64-ccov/debug" + }, + "metadata": { + "description": "Linux64-CCov Debug ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=3a71baea939144b4ec37805a932f0250c74986b1))", + "name": "build-linux64-ccov/debug", + "owner": "shindli@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/3a71baea939144b4ec37805a932f0250c74986b1/taskcluster/ci/build" + }, + "payload": { + "artifacts": { + "public/build": { + "expires": "2020-08-06T21:54:28.511Z", + "path": "/builds/worker/artifacts/", + "type": "directory" + }, + "public/code-coverage-grcov.zip": { + "expires": "2020-08-06T21:54:28.511Z", + "path": "/builds/worker/workspace/build/src/obj-firefox/code-coverage-grcov.zip", + "type": "file" + }, + "public/logs": { + "expires": "2020-08-06T21:54:28.511Z", + "path": "/builds/worker/logs/", + "type": "directory" + } + }, + "cache": { + "gecko-level-3-checkouts-v3-dfc53bf3da270f670474": "/builds/worker/checkouts", + "gecko-level-3-mozilla-central-build-linux64-ccov-debug-workspace-v3-dfc53bf3da270f670474": "/builds/worker/workspace", + "gecko-level-3-tooltool-cache-v3-dfc53bf3da270f670474": "/builds/worker/tooltool-cache" + }, + "command": [ + "/builds/worker/bin/run-task", + "--gecko-checkout=/builds/worker/workspace/build/src", + "--fetch-hgfingerprint", + "--", + "/builds/worker/workspace/build/src/taskcluster/scripts/builder/build-linux.sh" + ], + "env": { + "ACCEPTED_MAR_CHANNEL_IDS": "firefox-mozilla-central", + "EXTRA_MOZHARNESS_CONFIG": "{\"update_channel\": \"nightly\", \"mozconfig_variant\": \"code-coverage-debug\"}", + "FORCE_GCC": "1", + "GECKO_BASE_REPOSITORY": "https://hg.mozilla.org/mozilla-unified", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "GECKO_HEAD_REV": "3a71baea939144b4ec37805a932f0250c74986b1", + "GECKO_PATH": "/builds/worker/workspace/build/src", + "HG_STORE_PATH": "/builds/worker/checkouts/hg-store", + "MAR_CHANNEL_ID": "firefox-mozilla-central", + "MH_BRANCH": "mozilla-central", + "MH_BUILD_POOL": "taskcluster", + "MH_CUSTOM_BUILD_VARIANT_CFG": "code-coverage-debug", + "MOZHARNESS_ACTIONS": "get-secrets build check-test", + "MOZHARNESS_CONFIG": "builds/releng_base_firefox.py builds/releng_base_linux_64_builds.py", + "MOZHARNESS_SCRIPT": "mozharness/scripts/fx_desktop_build.py", + "MOZ_AUTOMATION": "1", + "MOZ_BUILD_DATE": "20190807215212", + "MOZ_DISABLE_FULL_SYMBOLS": "1", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.xz\", \"extract\": true, \"task\": \"Cs2T4_a0R8iH8ehZwDKkNg\"}]", + "MOZ_FETCHES_DIR": "fetches", + "MOZ_SCM_LEVEL": "3", + "MOZ_SOURCE_CHANGESET": "3a71baea939144b4ec37805a932f0250c74986b1", + "MOZ_SOURCE_REPO": "https://hg.mozilla.org/mozilla-central", + "MOZ_TOOLCHAINS": "public/build/clang.tar.xz@aRGv3xq8S2-B0iqD2A9zVA public/build/rustc.tar.xz@Gk89DrymQw-mUJsTOKwiUQ public/build/gcc.tar.xz@eSvT_7mITMGkjllEwe2ZRw public/build/cbindgen.tar.xz@bTuzhPGaRkObDO1CbPNpRA public/build/sccache.tar.xz@cYYO3myCSG6HvQ5AU_59vA public/build/nasm.tar.bz2@T9HmXbrnT4y-fk7ikXyalw public/build/node.tar.xz@WtlBHsaBQni-PcKdJD7FwQ", + "NEED_XVFB": "true", + "PYTHONUNBUFFERED": "1", + "SCCACHE_IDLE_TIMEOUT": "0", + "TASKCLUSTER_CACHES": "/builds/worker/checkouts;/builds/worker/tooltool-cache;/builds/worker/workspace", + "TASKCLUSTER_VOLUMES": "/builds/worker/checkouts;/builds/worker/tooltool-cache;/builds/worker/workspace", + "TOOLTOOL_CACHE": "/builds/worker/tooltool-cache", + "UPLOAD_DIR": "/builds/worker/artifacts/", + "USE_SCCACHE": "1" + }, + "features": { + "chainOfTrust": true, + "taskclusterProxy": true + }, + "image": { + "path": "public/image.tar.zst", + "taskId": "LFxhtjbxTg6AwyCP8Wk0Vw", + "type": "task-image" + }, + "maxRunTime": 7200, + "onExitStatus": { + "purgeCaches": [ + 72 + ], + "retry": [ + 4, + 72 + ] + } + }, + "priority": "medium", + "provisionerId": "aws-provisioner-v1", + "requires": "all-completed", + "retries": 5, + "routes": [ + "index.gecko.v2.mozilla-central.latest.firefox.linux64-ccov-debug", + "index.gecko.v2.mozilla-central.pushdate.2019.08.07.20190807215212.firefox.linux64-ccov-debug", + "index.gecko.v2.mozilla-central.pushlog-id.36406.firefox.linux64-ccov-debug", + "index.gecko.v2.mozilla-central.revision.3a71baea939144b4ec37805a932f0250c74986b1.firefox.linux64-ccov-debug", + "index.gecko.v2.trunk.revision.3a71baea939144b4ec37805a932f0250c74986b1.firefox.linux64-ccov-debug", + "tc-treeherder.v2.mozilla-central.3a71baea939144b4ec37805a932f0250c74986b1.36406" + ], + "schedulerId": "gecko-level-3", + "scopes": [ + "secrets:get:project/releng/gecko/build/level-3/*", + "secrets:get:project/taskcluster/gecko/hgfingerprint", + "secrets:get:project/taskcluster/gecko/hgmointernal", + "project:releng:services/tooltool/api/download/public", + "assume:project:taskcluster:gecko:level-3-sccache-buckets", + "docker-worker:cache:gecko-level-3-mozilla-central-build-linux64-ccov-debug-workspace-v3-dfc53bf3da270f670474", + "docker-worker:cache:gecko-level-3-checkouts-v3-dfc53bf3da270f670474", + "docker-worker:cache:gecko-level-3-tooltool-cache-v3-dfc53bf3da270f670474" + ], + "tags": { + "createdForUser": "shindli@mozilla.com", + "kind": "build", + "label": "build-linux64-ccov/debug", + "os": "linux", + "retrigger": "false", + "worker-implementation": "docker-worker" + }, + "taskGroupId": "PUZr6C8WR9Cmw3LeL9qotw", + "workerType": "gecko-3-b-linux" +} \ No newline at end of file diff --git a/bot/tests/fixtures/build-win64-ccov/debug.json b/bot/tests/fixtures/build-win64-ccov/debug.json new file mode 100644 index 000000000..62963cfcc --- /dev/null +++ b/bot/tests/fixtures/build-win64-ccov/debug.json @@ -0,0 +1,144 @@ +{ + "created": "2019-08-07T21:54:27.031Z", + "deadline": "2019-08-08T21:54:27.031Z", + "dependencies": [ + "AR2tD98sRXO3qlHtZIhAFA", + "DVFc3YzHTc2jWwVfyXDVQw", + "M94-BZ6ZQM6rgBI2K3U4mA", + "OBb8ONVkRf265Aq145ikeQ", + "WfFJLWbiSimhm-Eq_6St_g", + "bVpuwUYmQCqjPY-Ynu1YZQ", + "dPnEY7lxSl-gzcC7X83PjA", + "ezPFOE87TraJEHbAaZrnHg", + "PUZr6C8WR9Cmw3LeL9qotw" + ], + "expires": "2020-08-06T21:54:27.031Z", + "extra": { + "index": { + "rank": 0 + }, + "parent": "PUZr6C8WR9Cmw3LeL9qotw", + "treeherder": { + "collection": { + "ccov": true + }, + "jobKind": "build", + "machine": { + "platform": "windows2012-64" + }, + "symbol": "B", + "tier": 2 + }, + "treeherder-platform": "windows2012-64/ccov" + }, + "metadata": { + "description": "Win64 Debug Code Coverage ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=3a71baea939144b4ec37805a932f0250c74986b1))", + "name": "build-win64-ccov/debug", + "owner": "shindli@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/3a71baea939144b4ec37805a932f0250c74986b1/taskcluster/ci/build" + }, + "payload": { + "artifacts": [ + { + "name": "public/code-coverage-grcov.zip", + "path": "build\\src\\obj-firefox\\code-coverage-grcov.zip", + "type": "file" + }, + { + "name": "public/logs", + "path": "logs", + "type": "directory" + }, + { + "name": "public/build", + "path": "public/build", + "type": "directory" + } + ], + "command": [ + ":: sccache currently uses the full compiler commandline as input to the\n:: cache hash key, so create a symlink to the task dir and build from\n:: the symlink dir to get consistent paths.\nif exist z:\\build rmdir z:\\build", + "mklink /d z:\\build %cd%", + "icacls z:\\build /grant *S-1-1-0:D /L", + "cd /d z:\\build", + "C:/mozilla-build/python3/python3.exe run-task --gecko-checkout=./build/src -- c:/mozilla-build/python/python.exe %GECKO_PATH%/testing/mozharness/scripts/fx_desktop_build.py --config builds/releng_base_firefox.py --config builds/taskcluster_base_windows.py --config builds/taskcluster_base_win64.py --config builds/taskcluster_sub_win64/ccov_debug.py --branch mozilla-central --work-dir %cd:Z:=z:%\\build --append-env-variables-from-configs" + ], + "env": { + "ACCEPTED_MAR_CHANNEL_IDS": "firefox-mozilla-central", + "EXTRA_MOZHARNESS_CONFIG": "{\"update_channel\": \"nightly\", \"mozconfig_variant\": \"code-coverage\"}", + "GECKO_BASE_REPOSITORY": "https://hg.mozilla.org/mozilla-unified", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "GECKO_HEAD_REV": "3a71baea939144b4ec37805a932f0250c74986b1", + "GECKO_PATH": "./build/src", + "HG_STORE_PATH": "y:/hg-shared", + "MAR_CHANNEL_ID": "firefox-mozilla-central", + "MH_BRANCH": "mozilla-central", + "MOZ_AUTOMATION": "1", + "MOZ_BUILD_DATE": "20190807215212", + "MOZ_DISABLE_FULL_SYMBOLS": "1", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.bz2\", \"extract\": true, \"task\": \"bVpuwUYmQCqjPY-Ynu1YZQ\"}]", + "MOZ_FETCHES_DIR": "fetches", + "MOZ_SCM_LEVEL": "3", + "MOZ_SIMPLE_PACKAGE_NAME": "target", + "MOZ_SOURCE_CHANGESET": "3a71baea939144b4ec37805a932f0250c74986b1", + "MOZ_SOURCE_REPO": "https://hg.mozilla.org/mozilla-central", + "MOZ_TOOLCHAINS": "public/build/clang.tar.bz2@dPnEY7lxSl-gzcC7X83PjA public/build/rustc.tar.xz@ezPFOE87TraJEHbAaZrnHg public/build/rust-size.tar.bz2@DVFc3YzHTc2jWwVfyXDVQw public/build/cbindgen.tar.bz2@M94-BZ6ZQM6rgBI2K3U4mA public/build/sccache.tar.bz2@AR2tD98sRXO3qlHtZIhAFA public/build/nasm.tar.bz2@OBb8ONVkRf265Aq145ikeQ public/build/node.tar.bz2@WfFJLWbiSimhm-Eq_6St_g", + "PYTHONPATH": "./build/src/testing/mozbase/manifestparser;./build/src/testing/mozbase/mozinfo;./build/src/testing/mozbase/mozfile;./build/src/testing/mozbase/mozprocess;./build/src/third_party/python/six", + "SCCACHE_IDLE_TIMEOUT": "0", + "TOOLTOOL_MANIFEST": "browser/config/tooltool-manifests/win64/releng.manifest", + "USE_SCCACHE": "1" + }, + "features": { + "chainOfTrust": true, + "taskclusterProxy": true + }, + "maxRunTime": 7200, + "mounts": [ + { + "content": { + "url": "https://hg.mozilla.org/mozilla-central/raw-file/3a71baea939144b4ec37805a932f0250c74986b1/taskcluster/scripts/run-task" + }, + "file": "./run-task" + }, + { + "content": { + "url": "https://hg.mozilla.org/mozilla-central/raw-file/3a71baea939144b4ec37805a932f0250c74986b1/taskcluster/scripts/misc/fetch-content" + }, + "file": "./fetch-content" + } + ], + "onExitStatus": { + "retry": [ + 1073807364, + 3221225786 + ] + } + }, + "priority": "medium", + "provisionerId": "aws-provisioner-v1", + "requires": "all-completed", + "retries": 5, + "routes": [ + "index.gecko.v2.mozilla-central.latest.firefox.win64-ccov-debug", + "index.gecko.v2.mozilla-central.pushdate.2019.08.07.20190807215212.firefox.win64-ccov-debug", + "index.gecko.v2.mozilla-central.pushlog-id.36406.firefox.win64-ccov-debug", + "index.gecko.v2.mozilla-central.revision.3a71baea939144b4ec37805a932f0250c74986b1.firefox.win64-ccov-debug", + "index.gecko.v2.trunk.revision.3a71baea939144b4ec37805a932f0250c74986b1.firefox.win64-ccov-debug", + "tc-treeherder.v2.mozilla-central.3a71baea939144b4ec37805a932f0250c74986b1.36406" + ], + "schedulerId": "gecko-level-3", + "scopes": [ + "secrets:get:project/releng/gecko/build/level-3/*", + "secrets:get:project/taskcluster/gecko/hgfingerprint", + "secrets:get:project/taskcluster/gecko/hgmointernal" + ], + "tags": { + "createdForUser": "shindli@mozilla.com", + "kind": "build", + "label": "build-win64-ccov/debug", + "os": "windows", + "retrigger": "false", + "worker-implementation": "generic-worker" + }, + "taskGroupId": "PUZr6C8WR9Cmw3LeL9qotw", + "workerType": "gecko-3-b-win2012" +} \ No newline at end of file diff --git a/bot/tests/fixtures/build-win64/debug.json b/bot/tests/fixtures/build-win64/debug.json new file mode 100644 index 000000000..9357d91ba --- /dev/null +++ b/bot/tests/fixtures/build-win64/debug.json @@ -0,0 +1,112 @@ +{ + "provisionerId": "aws-provisioner-v1", + "workerType": "gecko-3-b-win2012", + "schedulerId": "gecko-level-3", + "taskGroupId": "Mu6w3n-dS9GOfrv6wGOtvg", + "dependencies": [ + "A2glmsCuQP6RKiZ2b64GWw", + "A2x8ujDgTjiUU55Ym0vKFg", + "GpEX9Ol1RRKqxoUtKaEe3Q", + "HdSEPz7vQTCG528C4aPYLA", + "HeAtunPjSe6ovqMjikX_cQ", + "LebTjyemRzylVAXC0W52jA", + "cz8EDILrTYinz5bdpsJUxQ", + "Mu6w3n-dS9GOfrv6wGOtvg" + ], + "requires": "all-completed", + "routes": [ + "index.gecko.v2.mozilla-central.latest.firefox.win64-debug", + "index.gecko.v2.mozilla-central.pushdate.2019.03.28.20190328173141.firefox.win64-debug", + "index.gecko.v2.mozilla-central.pushlog-id.35772.firefox.win64-debug", + "index.gecko.v2.mozilla-central.revision.e31357c7759379d2279b6883cb09c91997bfaa5d.firefox.win64-debug", + "index.gecko.v2.trunk.revision.e31357c7759379d2279b6883cb09c91997bfaa5d.firefox.win64-debug", + "tc-treeherder.v2.mozilla-central.e31357c7759379d2279b6883cb09c91997bfaa5d.35772" + ], + "priority": "medium", + "retries": 5, + "created": "2019-03-28T17:38:38.226Z", + "deadline": "2019-03-29T17:38:38.226Z", + "expires": "2020-03-27T17:38:38.226Z", + "scopes": [ + "secrets:get:project/releng/gecko/build/level-3/*", + "secrets:get:project/taskcluster/gecko/hgfingerprint" + ], + "payload": { + "maxRunTime": 7200, + "artifacts": [ + { + "path": "logs", + "type": "directory", + "name": "public/logs" + }, + { + "path": "public/build", + "type": "directory", + "name": "public/build" + } + ], + "command": [ + ":: sccache currently uses the full compiler commandline as input to the\n:: cache hash key, so create a symlink to the task dir and build from\n:: the symlink dir to get consistent paths.\nif exist z:\\build rmdir z:\\build", + "mklink /d z:\\build %cd%", + "icacls z:\\build /grant *S-1-1-0:D /L", + "cd /d z:\\build", + "\"c:\\Program Files\\Mercurial\\hg.exe\" robustcheckout --sharebase y:\\hg-shared --purge --upstream https://hg.mozilla.org/mozilla-unified --revision e31357c7759379d2279b6883cb09c91997bfaa5d https://hg.mozilla.org/mozilla-central .\\build\\src", + ":: TinderboxPrint:e31357c7759379d2279b6883cb09c91997bfaa5d\n", + "c:\\mozilla-build\\python\\python.exe .\\build\\src\\testing\\mozharness\\scripts\\fx_desktop_build.py --config builds\\releng_base_firefox.py --config builds\\taskcluster_base_windows.py --config builds\\taskcluster_base_win64.py --config builds\\taskcluster_sub_win64\\debug.py --branch mozilla-central --work-dir %cd:Z:=z:%\\build --append-env-variables-from-configs" + ], + "features": { + "taskclusterProxy": true, + "chainOfTrust": true + }, + "env": { + "MOZ_SOURCE_CHANGESET": "e31357c7759379d2279b6883cb09c91997bfaa5d", + "MOZ_BUILD_DATE": "20190328173141", + "MOZ_SOURCE_REPO": "https://hg.mozilla.org/mozilla-central", + "HG_STORE_PATH": "y:/hg-shared", + "GECKO_HEAD_REV": "e31357c7759379d2279b6883cb09c91997bfaa5d", + "MH_BRANCH": "mozilla-central", + "GECKO_PATH": "./build/src", + "MOZ_SCM_LEVEL": "3", + "EXTRA_MOZHARNESS_CONFIG": "{\"update_channel\": \"nightly\", \"mozconfig_variant\": \"debug\"}", + "MOZ_TOOLCHAINS": "public/build/clang.tar.bz2@HdSEPz7vQTCG528C4aPYLA public/build/rustc.tar.bz2@cz8EDILrTYinz5bdpsJUxQ public/build/rust-size.tar.bz2@HeAtunPjSe6ovqMjikX_cQ public/build/cbindgen.tar.bz2@A2glmsCuQP6RKiZ2b64GWw public/build/sccache2.tar.bz2@GpEX9Ol1RRKqxoUtKaEe3Q public/build/nasm.tar.bz2@A2x8ujDgTjiUU55Ym0vKFg public/build/node.tar.bz2@LebTjyemRzylVAXC0W52jA", + "MOZ_SIMPLE_PACKAGE_NAME": "target", + "SCCACHE_IDLE_TIMEOUT": "0", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "TOOLTOOL_MANIFEST": "browser/config/tooltool-manifests/win64/releng.manifest", + "USE_SCCACHE": "1", + "MOZ_AUTOMATION": "1", + "GECKO_BASE_REPOSITORY": "https://hg.mozilla.org/mozilla-unified" + } + }, + "metadata": { + "owner": "opoprus@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/e31357c7759379d2279b6883cb09c91997bfaa5d/taskcluster/ci/build", + "description": "Win64 Debug ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=e31357c7759379d2279b6883cb09c91997bfaa5d))", + "name": "build-win64/debug" + }, + "tags": { + "os": "windows", + "createdForUser": "opoprus@mozilla.com", + "worker-implementation": "generic-worker", + "kind": "build", + "label": "build-win64/debug" + }, + "extra": { + "index": { + "rank": 1553794301 + }, + "treeherder": { + "machine": { + "platform": "windows2012-64" + }, + "tier": 1, + "symbol": "B", + "jobKind": "build", + "collection": { + "debug": true + } + }, + "treeherder-platform": "windows2012-64/debug", + "parent": "Mu6w3n-dS9GOfrv6wGOtvg" + } +} \ No newline at end of file diff --git a/bot/tests/fixtures/test-linux64-ccov/debug-cppunit.json b/bot/tests/fixtures/test-linux64-ccov/debug-cppunit.json new file mode 100644 index 000000000..cc97156a5 --- /dev/null +++ b/bot/tests/fixtures/test-linux64-ccov/debug-cppunit.json @@ -0,0 +1,145 @@ +{ + "provisionerId": "aws-provisioner-v1", + "workerType": "gecko-t-linux-xlarge", + "schedulerId": "gecko-level-3", + "taskGroupId": "Mu6w3n-dS9GOfrv6wGOtvg", + "dependencies": [ + "CGQi0Z1nQhizLPmm9d3wYQ", + "Ni08JmJYSd2ORiKH5wvxgA", + "VJu-1z_6RWqaheqWJvI2IQ" + ], + "requires": "all-completed", + "routes": [ + "tc-treeherder.v2.mozilla-central.e31357c7759379d2279b6883cb09c91997bfaa5d.35772", + "coalesce.v1.mozilla-central.266f2f38356a68adc022" + ], + "priority": "medium", + "retries": 5, + "created": "2019-03-28T17:39:44.655Z", + "deadline": "2019-03-29T17:39:44.655Z", + "expires": "2020-03-27T17:39:44.655Z", + "scopes": [ + "docker-worker:relengapi-proxy:tooltool.download.public", + "secrets:get:project/taskcluster/gecko/hgfingerprint", + "docker-worker:feature:allowPtrace", + "docker-worker:cache:gecko-level-3-tooltool-cache-v3-33ea6ead87f10b63cd64", + "docker-worker:cache:gecko-level-3-checkouts-v3-33ea6ead87f10b63cd64" + ], + "payload": { + "supersederUrl": "https://coalesce.mozilla-releng.net/v1/list/3600/5/mozilla-central.266f2f38356a68adc022", + "onExitStatus": { + "retry": [ + 4, + 72 + ], + "purgeCaches": [ + 72 + ] + }, + "maxRunTime": 3600, + "image": { + "path": "public/image.tar.zst", + "type": "task-image", + "taskId": "Ni08JmJYSd2ORiKH5wvxgA" + }, + "cache": { + "gecko-level-3-tooltool-cache-v3-33ea6ead87f10b63cd64": "/builds/worker/tooltool-cache", + "gecko-level-3-checkouts-v3-33ea6ead87f10b63cd64": "/builds/worker/checkouts" + }, + "artifacts": { + "public/logs/": { + "path": "/builds/worker/workspace/logs/", + "expires": "2020-03-27T17:39:44.655Z", + "type": "directory" + }, + "public/test": { + "path": "/builds/worker/artifacts/", + "expires": "2020-03-27T17:39:44.655Z", + "type": "directory" + }, + "public/test_info/": { + "path": "/builds/worker/workspace/build/blobber_upload_dir/", + "expires": "2020-03-27T17:39:44.655Z", + "type": "directory" + } + }, + "command": [ + "/builds/worker/bin/run-task", + "--", + "/builds/worker/bin/test-linux.sh", + "--installer-url=https://queue.taskcluster.net/v1/task/VJu-1z_6RWqaheqWJvI2IQ/artifacts/public/build/target.tar.bz2", + "--test-packages-url=https://queue.taskcluster.net/v1/task/VJu-1z_6RWqaheqWJvI2IQ/artifacts/public/build/target.test_packages.json", + "--cppunittest-suite=cppunittest", + "--code-coverage", + "--allow-software-gl-layers", + "--download-symbols=true" + ], + "env": { + "SCCACHE_DISABLE": "1", + "MOZ_NODE_PATH": "/usr/local/bin/node", + "TASKCLUSTER_CACHES": "/builds/worker/checkouts;/builds/worker/tooltool-cache", + "HG_STORE_PATH": "/builds/worker/checkouts/hg-store", + "MOZ_AUTOMATION": "1", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "GECKO_HEAD_REV": "e31357c7759379d2279b6883cb09c91997bfaa5d", + "MOZHARNESS_URL": "https://queue.taskcluster.net/v1/task/VJu-1z_6RWqaheqWJvI2IQ/artifacts/public/build/mozharness.zip", + "MOZHARNESS_SCRIPT": "desktop_unittest.py", + "NEED_WINDOW_MANAGER": "true", + "WORKING_DIR": "/builds/worker", + "GECKO_PATH": "/builds/worker/checkouts/gecko", + "TOOLTOOL_CACHE": "/builds/worker/tooltool-cache", + "ENABLE_E10S": "false", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.xz\", \"extract\": true, \"task\": \"CGQi0Z1nQhizLPmm9d3wYQ\"}]", + "TASKCLUSTER_VOLUMES": "/builds/worker/.cache;/builds/worker/checkouts;/builds/worker/tooltool-cache;/builds/worker/workspace", + "MOZHARNESS_CONFIG": "unittests/linux_unittest.py remove_executables.py", + "MOZ_FETCHES_DIR": "/builds/worker/fetches", + "MOZILLA_BUILD_URL": "https://queue.taskcluster.net/v1/task/VJu-1z_6RWqaheqWJvI2IQ/artifacts/public/build/target.tar.bz2", + "GECKO_BASE_REPOSITORY": "https://hg.mozilla.org/mozilla-unified", + "NEED_PULSEAUDIO": "true" + }, + "features": { + "taskclusterProxy": true, + "allowPtrace": true, + "relengAPIProxy": true + } + }, + "metadata": { + "owner": "opoprus@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/e31357c7759379d2279b6883cb09c91997bfaa5d/taskcluster/ci/test", + "description": "CPP Unit Tests ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=e31357c7759379d2279b6883cb09c91997bfaa5d))", + "name": "test-linux64-ccov/debug-cppunit" + }, + "tags": { + "os": "linux", + "createdForUser": "opoprus@mozilla.com", + "worker-implementation": "docker-worker", + "kind": "test", + "label": "test-linux64-ccov/debug-cppunit" + }, + "extra": { + "index": { + "rank": 0 + }, + "parent": "Mu6w3n-dS9GOfrv6wGOtvg", + "chunks": { + "current": 1, + "total": 1 + }, + "suite": { + "flavor": "cppunittest", + "name": "cppunittest" + }, + "treeherder": { + "machine": { + "platform": "linux64-ccov" + }, + "tier": 2, + "symbol": "Cpp", + "jobKind": "test", + "collection": { + "debug": true + } + }, + "treeherder-platform": "linux64-ccov/debug" + } +} \ No newline at end of file diff --git a/bot/tests/fixtures/test-linux64-ccov/debug-firefox-ui-functional-remote-e10s.json b/bot/tests/fixtures/test-linux64-ccov/debug-firefox-ui-functional-remote-e10s.json new file mode 100644 index 000000000..c346575fa --- /dev/null +++ b/bot/tests/fixtures/test-linux64-ccov/debug-firefox-ui-functional-remote-e10s.json @@ -0,0 +1,150 @@ +{ + "created": "2019-08-07T21:54:50.966Z", + "deadline": "2019-08-08T21:54:50.966Z", + "dependencies": [ + "Cs2T4_a0R8iH8ehZwDKkNg", + "I8yOrSoxTby-wIwdThZZZw", + "OvM-EZLZQgSyXr67GhKKCw" + ], + "expires": "2020-08-06T21:54:50.966Z", + "extra": { + "chunks": { + "current": 1, + "total": 1 + }, + "index": { + "rank": 0 + }, + "parent": "PUZr6C8WR9Cmw3LeL9qotw", + "suite": "firefox-ui-functional-remote", + "treeherder": { + "collection": { + "debug": true + }, + "groupName": "Firefox functional tests (remote)", + "groupSymbol": "Fxfn-r", + "jobKind": "test", + "machine": { + "platform": "linux64-ccov" + }, + "symbol": "en-US", + "tier": 2 + }, + "treeherder-platform": "linux64-ccov/debug" + }, + "metadata": { + "description": "Firefox-ui-tests functional run ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=3a71baea939144b4ec37805a932f0250c74986b1))", + "name": "test-linux64-ccov/debug-firefox-ui-functional-remote-e10s", + "owner": "shindli@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/3a71baea939144b4ec37805a932f0250c74986b1/taskcluster/ci/test" + }, + "payload": { + "artifacts": { + "public/logs/": { + "expires": "2020-08-06T21:54:50.966Z", + "path": "/builds/worker/workspace/logs/", + "type": "directory" + }, + "public/test": { + "expires": "2020-08-06T21:54:50.966Z", + "path": "/builds/worker/artifacts/", + "type": "directory" + }, + "public/test_info/": { + "expires": "2020-08-06T21:54:50.966Z", + "path": "/builds/worker/workspace/build/blobber_upload_dir/", + "type": "directory" + } + }, + "cache": { + "gecko-level-3-checkouts-v3-dfc53bf3da270f670474": "/builds/worker/checkouts", + "gecko-level-3-tooltool-cache-v3-dfc53bf3da270f670474": "/builds/worker/tooltool-cache" + }, + "command": [ + "/builds/worker/bin/run-task", + "--fetch-hgfingerprint", + "--", + "/builds/worker/bin/test-linux.sh", + "--tag", + "remote", + "--code-coverage", + "--setpref=media.peerconnection.mtransport_process=false", + "--setpref=network.process.enabled=false", + "--allow-software-gl-layers", + "--download-symbols=true" + ], + "env": { + "ENABLE_E10S": "true", + "EXTRA_MOZHARNESS_CONFIG": "{\"test_packages_url\": \"https://queue.taskcluster.net/v1/task/OvM-EZLZQgSyXr67GhKKCw/artifacts/public/build/target.test_packages.json\", \"installer_url\": \"https://queue.taskcluster.net/v1/task/OvM-EZLZQgSyXr67GhKKCw/artifacts/public/build/target.tar.bz2\"}", + "GECKO_BASE_REPOSITORY": "https://hg.mozilla.org/mozilla-unified", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "GECKO_HEAD_REV": "3a71baea939144b4ec37805a932f0250c74986b1", + "GECKO_PATH": "/builds/worker/checkouts/gecko", + "HG_STORE_PATH": "/builds/worker/checkouts/hg-store", + "MOZHARNESS_CONFIG": "firefox_ui_tests/taskcluster.py remove_executables.py", + "MOZHARNESS_SCRIPT": "firefox_ui_tests/functional.py", + "MOZHARNESS_URL": "https://queue.taskcluster.net/v1/task/OvM-EZLZQgSyXr67GhKKCw/artifacts/public/build/mozharness.zip", + "MOZILLA_BUILD_URL": "https://queue.taskcluster.net/v1/task/OvM-EZLZQgSyXr67GhKKCw/artifacts/public/build/target.tar.bz2", + "MOZ_AUTOMATION": "1", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.xz\", \"extract\": true, \"task\": \"Cs2T4_a0R8iH8ehZwDKkNg\"}]", + "MOZ_FETCHES_DIR": "fetches", + "MOZ_NODE_PATH": "/usr/local/bin/node", + "MOZ_SCM_LEVEL": "3", + "NEED_COMPIZ": "true", + "NEED_PULSEAUDIO": "true", + "NEED_WINDOW_MANAGER": "true", + "SCCACHE_DISABLE": "1", + "TASKCLUSTER_CACHES": "/builds/worker/checkouts;/builds/worker/tooltool-cache", + "TASKCLUSTER_VOLUMES": "/builds/worker/.cache;/builds/worker/checkouts;/builds/worker/tooltool-cache;/builds/worker/workspace", + "TOOLTOOL_CACHE": "/builds/worker/tooltool-cache", + "WORKING_DIR": "/builds/worker" + }, + "features": { + "allowPtrace": true, + "taskclusterProxy": true + }, + "image": { + "path": "public/image.tar.zst", + "taskId": "I8yOrSoxTby-wIwdThZZZw", + "type": "task-image" + }, + "maxRunTime": 5400, + "onExitStatus": { + "purgeCaches": [ + 72 + ], + "retry": [ + 4, + 72 + ] + }, + "supersederUrl": "https://coalesce.mozilla-releng.net/v1/list/3600/5/mozilla-central.2b645a937bdbb303542e" + }, + "priority": "medium", + "provisionerId": "aws-provisioner-v1", + "requires": "all-completed", + "retries": 5, + "routes": [ + "tc-treeherder.v2.mozilla-central.3a71baea939144b4ec37805a932f0250c74986b1.36406", + "coalesce.v1.mozilla-central.2b645a937bdbb303542e" + ], + "schedulerId": "gecko-level-3", + "scopes": [ + "secrets:get:project/taskcluster/gecko/hgfingerprint", + "secrets:get:project/taskcluster/gecko/hgmointernal", + "project:releng:services/tooltool/api/download/public", + "docker-worker:feature:allowPtrace", + "docker-worker:cache:gecko-level-3-checkouts-v3-dfc53bf3da270f670474", + "docker-worker:cache:gecko-level-3-tooltool-cache-v3-dfc53bf3da270f670474" + ], + "tags": { + "createdForUser": "shindli@mozilla.com", + "kind": "test", + "label": "test-linux64-ccov/debug-firefox-ui-functional-remote-e10s", + "os": "linux", + "retrigger": "true", + "worker-implementation": "docker-worker" + }, + "taskGroupId": "PUZr6C8WR9Cmw3LeL9qotw", + "workerType": "gecko-t-linux-xlarge" +} \ No newline at end of file diff --git a/bot/tests/fixtures/test-linux64-ccov/debug-mochitest-1.json b/bot/tests/fixtures/test-linux64-ccov/debug-mochitest-1.json new file mode 100644 index 000000000..734dfd170 --- /dev/null +++ b/bot/tests/fixtures/test-linux64-ccov/debug-mochitest-1.json @@ -0,0 +1,157 @@ +{ + "provisionerId": "aws-provisioner-v1", + "workerType": "gecko-t-linux-xlarge", + "schedulerId": "gecko-level-3", + "taskGroupId": "Mu6w3n-dS9GOfrv6wGOtvg", + "dependencies": [ + "CGQi0Z1nQhizLPmm9d3wYQ", + "Ni08JmJYSd2ORiKH5wvxgA", + "VJu-1z_6RWqaheqWJvI2IQ" + ], + "requires": "all-completed", + "routes": [ + "tc-treeherder.v2.mozilla-central.e31357c7759379d2279b6883cb09c91997bfaa5d.35772", + "coalesce.v1.mozilla-central.72a408b230326a5f5576" + ], + "priority": "medium", + "retries": 5, + "created": "2019-03-28T17:39:11.229Z", + "deadline": "2019-03-29T17:39:11.229Z", + "expires": "2020-03-27T17:39:11.229Z", + "scopes": [ + "docker-worker:relengapi-proxy:tooltool.download.public", + "secrets:get:project/taskcluster/gecko/hgfingerprint", + "docker-worker:feature:allowPtrace", + "docker-worker:capability:device:loopbackVideo", + "docker-worker:cache:gecko-level-3-tooltool-cache-v3-33ea6ead87f10b63cd64", + "docker-worker:cache:gecko-level-3-checkouts-v3-33ea6ead87f10b63cd64" + ], + "payload": { + "supersederUrl": "https://coalesce.mozilla-releng.net/v1/list/3600/5/mozilla-central.72a408b230326a5f5576", + "onExitStatus": { + "retry": [ + 4, + 72 + ], + "purgeCaches": [ + 72 + ] + }, + "maxRunTime": 5400, + "image": { + "path": "public/image.tar.zst", + "type": "task-image", + "taskId": "Ni08JmJYSd2ORiKH5wvxgA" + }, + "cache": { + "gecko-level-3-tooltool-cache-v3-33ea6ead87f10b63cd64": "/builds/worker/tooltool-cache", + "gecko-level-3-checkouts-v3-33ea6ead87f10b63cd64": "/builds/worker/checkouts" + }, + "capabilities": { + "devices": { + "loopbackVideo": true + } + }, + "artifacts": { + "public/logs/": { + "path": "/builds/worker/workspace/logs/", + "expires": "2020-03-27T17:39:11.229Z", + "type": "directory" + }, + "public/test": { + "path": "/builds/worker/artifacts/", + "expires": "2020-03-27T17:39:11.229Z", + "type": "directory" + }, + "public/test_info/": { + "path": "/builds/worker/workspace/build/blobber_upload_dir/", + "expires": "2020-03-27T17:39:11.229Z", + "type": "directory" + } + }, + "command": [ + "/builds/worker/bin/run-task", + "--", + "/builds/worker/bin/test-linux.sh", + "--installer-url=https://queue.taskcluster.net/v1/task/VJu-1z_6RWqaheqWJvI2IQ/artifacts/public/build/target.tar.bz2", + "--test-packages-url=https://queue.taskcluster.net/v1/task/VJu-1z_6RWqaheqWJvI2IQ/artifacts/public/build/target.test_packages.json", + "--mochitest-suite=plain-chunked", + "--code-coverage", + "--e10s", + "--total-chunk=16", + "--this-chunk=1", + "--download-symbols=true" + ], + "env": { + "MOZ_AUTOMATION": "1", + "MOCHITEST_FLAVOR": "plain", + "TOOLTOOL_CACHE": "/builds/worker/tooltool-cache", + "MOZ_FETCHES_DIR": "/builds/worker/fetches", + "MOZHARNESS_SCRIPT": "desktop_unittest.py", + "MOZ_NODE_PATH": "/usr/local/bin/node", + "HG_STORE_PATH": "/builds/worker/checkouts/hg-store", + "MOZILLA_BUILD_URL": "https://queue.taskcluster.net/v1/task/VJu-1z_6RWqaheqWJvI2IQ/artifacts/public/build/target.tar.bz2", + "GECKO_PATH": "/builds/worker/checkouts/gecko", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "SCCACHE_DISABLE": "1", + "GECKO_HEAD_REV": "e31357c7759379d2279b6883cb09c91997bfaa5d", + "TASKCLUSTER_VOLUMES": "/builds/worker/.cache;/builds/worker/checkouts;/builds/worker/tooltool-cache;/builds/worker/workspace", + "MOZHARNESS_URL": "https://queue.taskcluster.net/v1/task/VJu-1z_6RWqaheqWJvI2IQ/artifacts/public/build/mozharness.zip", + "GECKO_BASE_REPOSITORY": "https://hg.mozilla.org/mozilla-unified", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.xz\", \"extract\": true, \"task\": \"CGQi0Z1nQhizLPmm9d3wYQ\"}]", + "TASKCLUSTER_CACHES": "/builds/worker/checkouts;/builds/worker/tooltool-cache", + "WORKING_DIR": "/builds/worker", + "NEED_PULSEAUDIO": "true", + "ENABLE_E10S": "true", + "NEED_WINDOW_MANAGER": "true", + "MOZHARNESS_CONFIG": "unittests/linux_unittest.py remove_executables.py" + }, + "features": { + "taskclusterProxy": true, + "allowPtrace": true, + "relengAPIProxy": true + } + }, + "metadata": { + "owner": "opoprus@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/e31357c7759379d2279b6883cb09c91997bfaa5d/taskcluster/ci/test", + "description": "Mochitest plain run ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=e31357c7759379d2279b6883cb09c91997bfaa5d))", + "name": "test-linux64-ccov/debug-mochitest-e10s-1" + }, + "tags": { + "kind": "test", + "worker-implementation": "docker-worker", + "createdForUser": "opoprus@mozilla.com", + "label": "test-linux64-ccov/debug-mochitest-e10s-1", + "test-type": "mochitest", + "os": "linux" + }, + "extra": { + "index": { + "rank": 0 + }, + "parent": "Mu6w3n-dS9GOfrv6wGOtvg", + "chunks": { + "current": 1, + "total": 16 + }, + "suite": { + "flavor": "plain-chunked", + "name": "mochitest" + }, + "treeherder": { + "jobKind": "test", + "groupSymbol": "M-e10s", + "collection": { + "debug": true + }, + "machine": { + "platform": "linux64-ccov" + }, + "groupName": "Mochitests with e10s", + "tier": 2, + "symbol": "1" + }, + "treeherder-platform": "linux64-ccov/debug" + } +} \ No newline at end of file diff --git a/bot/tests/fixtures/test-linux64-ccov/debug-mochitest-e10s-7.json b/bot/tests/fixtures/test-linux64-ccov/debug-mochitest-e10s-7.json new file mode 100644 index 000000000..d03bdc12c --- /dev/null +++ b/bot/tests/fixtures/test-linux64-ccov/debug-mochitest-e10s-7.json @@ -0,0 +1,158 @@ +{ + "created": "2019-08-07T21:55:02.555Z", + "deadline": "2019-08-08T21:55:02.555Z", + "dependencies": [ + "Cs2T4_a0R8iH8ehZwDKkNg", + "I8yOrSoxTby-wIwdThZZZw", + "OvM-EZLZQgSyXr67GhKKCw" + ], + "expires": "2020-08-06T21:55:02.555Z", + "extra": { + "chunks": { + "current": 7, + "total": 16 + }, + "index": { + "rank": 0 + }, + "parent": "PUZr6C8WR9Cmw3LeL9qotw", + "suite": "mochitest-plain-chunked", + "treeherder": { + "collection": { + "debug": true + }, + "groupName": "Mochitests", + "groupSymbol": "M", + "jobKind": "test", + "machine": { + "platform": "linux64-ccov" + }, + "symbol": "7", + "tier": 2 + }, + "treeherder-platform": "linux64-ccov/debug" + }, + "metadata": { + "description": "Mochitest plain run ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=3a71baea939144b4ec37805a932f0250c74986b1))", + "name": "test-linux64-ccov/debug-mochitest-e10s-7", + "owner": "shindli@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/3a71baea939144b4ec37805a932f0250c74986b1/taskcluster/ci/test" + }, + "payload": { + "artifacts": { + "public/logs/": { + "expires": "2020-08-06T21:55:02.555Z", + "path": "/builds/worker/workspace/logs/", + "type": "directory" + }, + "public/test": { + "expires": "2020-08-06T21:55:02.555Z", + "path": "/builds/worker/artifacts/", + "type": "directory" + }, + "public/test_info/": { + "expires": "2020-08-06T21:55:02.555Z", + "path": "/builds/worker/workspace/build/blobber_upload_dir/", + "type": "directory" + } + }, + "cache": { + "gecko-level-3-checkouts-v3-dfc53bf3da270f670474": "/builds/worker/checkouts", + "gecko-level-3-tooltool-cache-v3-dfc53bf3da270f670474": "/builds/worker/tooltool-cache" + }, + "capabilities": { + "devices": { + "loopbackVideo": true + } + }, + "command": [ + "/builds/worker/bin/run-task", + "--fetch-hgfingerprint", + "--", + "/builds/worker/bin/test-linux.sh", + "--mochitest-suite=mochitest-plain-chunked", + "--code-coverage", + "--setpref=media.peerconnection.mtransport_process=false", + "--setpref=network.process.enabled=false", + "--total-chunk=16", + "--this-chunk=7", + "--download-symbols=true" + ], + "env": { + "ENABLE_E10S": "true", + "EXTRA_MOZHARNESS_CONFIG": "{\"test_packages_url\": \"https://queue.taskcluster.net/v1/task/OvM-EZLZQgSyXr67GhKKCw/artifacts/public/build/target.test_packages.json\", \"installer_url\": \"https://queue.taskcluster.net/v1/task/OvM-EZLZQgSyXr67GhKKCw/artifacts/public/build/target.tar.bz2\"}", + "GECKO_BASE_REPOSITORY": "https://hg.mozilla.org/mozilla-unified", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "GECKO_HEAD_REV": "3a71baea939144b4ec37805a932f0250c74986b1", + "GECKO_PATH": "/builds/worker/checkouts/gecko", + "HG_STORE_PATH": "/builds/worker/checkouts/hg-store", + "MOCHITEST_FLAVOR": "plain", + "MOZHARNESS_CONFIG": "unittests/linux_unittest.py remove_executables.py", + "MOZHARNESS_SCRIPT": "desktop_unittest.py", + "MOZHARNESS_URL": "https://queue.taskcluster.net/v1/task/OvM-EZLZQgSyXr67GhKKCw/artifacts/public/build/mozharness.zip", + "MOZILLA_BUILD_URL": "https://queue.taskcluster.net/v1/task/OvM-EZLZQgSyXr67GhKKCw/artifacts/public/build/target.tar.bz2", + "MOZ_AUTOMATION": "1", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.xz\", \"extract\": true, \"task\": \"Cs2T4_a0R8iH8ehZwDKkNg\"}]", + "MOZ_FETCHES_DIR": "fetches", + "MOZ_NODE_PATH": "/usr/local/bin/node", + "MOZ_SCM_LEVEL": "3", + "NEED_COMPIZ": "true", + "NEED_PULSEAUDIO": "true", + "NEED_WINDOW_MANAGER": "true", + "SCCACHE_DISABLE": "1", + "TASKCLUSTER_CACHES": "/builds/worker/checkouts;/builds/worker/tooltool-cache", + "TASKCLUSTER_VOLUMES": "/builds/worker/.cache;/builds/worker/checkouts;/builds/worker/tooltool-cache;/builds/worker/workspace", + "TOOLTOOL_CACHE": "/builds/worker/tooltool-cache", + "WORKING_DIR": "/builds/worker" + }, + "features": { + "allowPtrace": true, + "taskclusterProxy": true + }, + "image": { + "path": "public/image.tar.zst", + "taskId": "I8yOrSoxTby-wIwdThZZZw", + "type": "task-image" + }, + "maxRunTime": 5400, + "onExitStatus": { + "purgeCaches": [ + 72 + ], + "retry": [ + 4, + 72 + ] + }, + "supersederUrl": "https://coalesce.mozilla-releng.net/v1/list/3600/5/mozilla-central.9fbb6e63720a04ba844b" + }, + "priority": "medium", + "provisionerId": "aws-provisioner-v1", + "requires": "all-completed", + "retries": 5, + "routes": [ + "tc-treeherder.v2.mozilla-central.3a71baea939144b4ec37805a932f0250c74986b1.36406", + "coalesce.v1.mozilla-central.9fbb6e63720a04ba844b" + ], + "schedulerId": "gecko-level-3", + "scopes": [ + "secrets:get:project/taskcluster/gecko/hgfingerprint", + "secrets:get:project/taskcluster/gecko/hgmointernal", + "project:releng:services/tooltool/api/download/public", + "docker-worker:feature:allowPtrace", + "docker-worker:capability:device:loopbackVideo", + "docker-worker:cache:gecko-level-3-checkouts-v3-dfc53bf3da270f670474", + "docker-worker:cache:gecko-level-3-tooltool-cache-v3-dfc53bf3da270f670474" + ], + "tags": { + "createdForUser": "shindli@mozilla.com", + "kind": "test", + "label": "test-linux64-ccov/debug-mochitest-e10s-7", + "os": "linux", + "retrigger": "true", + "test-type": "mochitest", + "worker-implementation": "docker-worker" + }, + "taskGroupId": "PUZr6C8WR9Cmw3LeL9qotw", + "workerType": "gecko-t-linux-xlarge" +} \ No newline at end of file diff --git a/bot/tests/fixtures/test-linux64/debug-mochitest-1.json b/bot/tests/fixtures/test-linux64/debug-mochitest-1.json new file mode 100644 index 000000000..03107dd20 --- /dev/null +++ b/bot/tests/fixtures/test-linux64/debug-mochitest-1.json @@ -0,0 +1,153 @@ +{ + "provisionerId": "aws-provisioner-v1", + "workerType": "gecko-t-linux-large", + "schedulerId": "gecko-level-3", + "taskGroupId": "Mu6w3n-dS9GOfrv6wGOtvg", + "dependencies": [ + "Ni08JmJYSd2ORiKH5wvxgA", + "ajAfM59jRx6OIauH3JLagQ" + ], + "requires": "all-completed", + "routes": [ + "tc-treeherder.v2.mozilla-central.e31357c7759379d2279b6883cb09c91997bfaa5d.35772", + "coalesce.v1.mozilla-central.5e99165554f02cbf4160" + ], + "priority": "medium", + "retries": 5, + "created": "2019-03-28T17:40:09.310Z", + "deadline": "2019-03-29T17:40:09.310Z", + "expires": "2020-03-27T17:40:09.310Z", + "scopes": [ + "docker-worker:relengapi-proxy:tooltool.download.public", + "secrets:get:project/taskcluster/gecko/hgfingerprint", + "docker-worker:feature:allowPtrace", + "docker-worker:capability:device:loopbackVideo", + "docker-worker:cache:gecko-level-3-tooltool-cache-v3-33ea6ead87f10b63cd64", + "docker-worker:cache:gecko-level-3-checkouts-v3-33ea6ead87f10b63cd64" + ], + "payload": { + "supersederUrl": "https://coalesce.mozilla-releng.net/v1/list/3600/5/mozilla-central.5e99165554f02cbf4160", + "onExitStatus": { + "retry": [ + 4, + 72 + ], + "purgeCaches": [ + 72 + ] + }, + "maxRunTime": 5400, + "image": { + "path": "public/image.tar.zst", + "type": "task-image", + "taskId": "Ni08JmJYSd2ORiKH5wvxgA" + }, + "cache": { + "gecko-level-3-tooltool-cache-v3-33ea6ead87f10b63cd64": "/builds/worker/tooltool-cache", + "gecko-level-3-checkouts-v3-33ea6ead87f10b63cd64": "/builds/worker/checkouts" + }, + "capabilities": { + "devices": { + "loopbackVideo": true + } + }, + "artifacts": { + "public/logs/": { + "path": "/builds/worker/workspace/logs/", + "expires": "2020-03-27T17:40:09.310Z", + "type": "directory" + }, + "public/test": { + "path": "/builds/worker/artifacts/", + "expires": "2020-03-27T17:40:09.310Z", + "type": "directory" + }, + "public/test_info/": { + "path": "/builds/worker/workspace/build/blobber_upload_dir/", + "expires": "2020-03-27T17:40:09.310Z", + "type": "directory" + } + }, + "command": [ + "/builds/worker/bin/run-task", + "--", + "/builds/worker/bin/test-linux.sh", + "--installer-url=https://queue.taskcluster.net/v1/task/ajAfM59jRx6OIauH3JLagQ/artifacts/public/build/target.tar.bz2", + "--test-packages-url=https://queue.taskcluster.net/v1/task/ajAfM59jRx6OIauH3JLagQ/artifacts/public/build/target.test_packages.json", + "--mochitest-suite=plain-chunked", + "--e10s", + "--total-chunk=16", + "--this-chunk=1", + "--download-symbols=true" + ], + "env": { + "NEED_PULSEAUDIO": "true", + "SCCACHE_DISABLE": "1", + "MOZ_NODE_PATH": "/usr/local/bin/node", + "TASKCLUSTER_CACHES": "/builds/worker/checkouts;/builds/worker/tooltool-cache", + "HG_STORE_PATH": "/builds/worker/checkouts/hg-store", + "MOZ_AUTOMATION": "1", + "GECKO_BASE_REPOSITORY": "https://hg.mozilla.org/mozilla-unified", + "GECKO_HEAD_REV": "e31357c7759379d2279b6883cb09c91997bfaa5d", + "MOCHITEST_FLAVOR": "plain", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "WORKING_DIR": "/builds/worker", + "GECKO_PATH": "/builds/worker/checkouts/gecko", + "TOOLTOOL_CACHE": "/builds/worker/tooltool-cache", + "ENABLE_E10S": "true", + "NEED_WINDOW_MANAGER": "true", + "TASKCLUSTER_VOLUMES": "/builds/worker/.cache;/builds/worker/checkouts;/builds/worker/tooltool-cache;/builds/worker/workspace", + "MOZHARNESS_CONFIG": "unittests/linux_unittest.py remove_executables.py", + "MOZHARNESS_SCRIPT": "desktop_unittest.py", + "MOZILLA_BUILD_URL": "https://queue.taskcluster.net/v1/task/ajAfM59jRx6OIauH3JLagQ/artifacts/public/build/target.tar.bz2", + "MOZHARNESS_URL": "https://queue.taskcluster.net/v1/task/ajAfM59jRx6OIauH3JLagQ/artifacts/public/build/mozharness.zip" + }, + "features": { + "taskclusterProxy": true, + "allowPtrace": true, + "relengAPIProxy": true + } + }, + "metadata": { + "owner": "opoprus@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/e31357c7759379d2279b6883cb09c91997bfaa5d/taskcluster/ci/test", + "description": "Mochitest plain run ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=e31357c7759379d2279b6883cb09c91997bfaa5d))", + "name": "test-linux64/debug-mochitest-e10s-1" + }, + "tags": { + "kind": "test", + "worker-implementation": "docker-worker", + "createdForUser": "opoprus@mozilla.com", + "label": "test-linux64/debug-mochitest-e10s-1", + "test-type": "mochitest", + "os": "linux" + }, + "extra": { + "index": { + "rank": 1553794301 + }, + "parent": "Mu6w3n-dS9GOfrv6wGOtvg", + "chunks": { + "current": 1, + "total": 16 + }, + "suite": { + "flavor": "plain-chunked", + "name": "mochitest" + }, + "treeherder": { + "jobKind": "test", + "groupSymbol": "M-e10s", + "collection": { + "debug": true + }, + "machine": { + "platform": "linux64" + }, + "groupName": "Mochitests with e10s", + "tier": 1, + "symbol": "1" + }, + "treeherder-platform": "linux64/debug" + } +} \ No newline at end of file diff --git a/bot/tests/fixtures/test-windows10-64-ccov/debug-cppunit.json b/bot/tests/fixtures/test-windows10-64-ccov/debug-cppunit.json new file mode 100644 index 000000000..91a5cce27 --- /dev/null +++ b/bot/tests/fixtures/test-windows10-64-ccov/debug-cppunit.json @@ -0,0 +1,97 @@ +{ + "provisionerId": "aws-provisioner-v1", + "workerType": "gecko-t-win10-64", + "schedulerId": "gecko-level-3", + "taskGroupId": "Mu6w3n-dS9GOfrv6wGOtvg", + "dependencies": [ + "Db0nxP-CRTKA7ak9LCYucA", + "brd6yPH_TEegeE8bjBLsxQ" + ], + "requires": "all-completed", + "routes": [ + "tc-treeherder.v2.mozilla-central.e31357c7759379d2279b6883cb09c91997bfaa5d.35772", + "coalesce.v1.mozilla-central.a08cf6d9fc36535ab7db" + ], + "priority": "medium", + "retries": 5, + "created": "2019-03-28T17:39:21.822Z", + "deadline": "2019-03-29T17:39:21.822Z", + "expires": "2020-03-27T17:39:21.822Z", + "scopes": [], + "payload": { + "supersederUrl": "https://coalesce.mozilla-releng.net/v1/list/3600/5/mozilla-central.a08cf6d9fc36535ab7db", + "maxRunTime": 3600, + "artifacts": [ + { + "path": "logs", + "type": "directory", + "name": "public/logs" + }, + { + "path": "build/blobber_upload_dir", + "type": "directory", + "name": "public/test_info" + } + ], + "command": [ + "c:\\mozilla-build\\python\\python.exe -u mozharness\\scripts\\desktop_unittest.py --cfg mozharness\\configs\\unittests\\win_taskcluster_unittest.py --cppunittest-suite=cppunittest --code-coverage --installer-url https://queue.taskcluster.net/v1/task/Db0nxP-CRTKA7ak9LCYucA/artifacts/public/build/target.zip --test-packages-url https://queue.taskcluster.net/v1/task/Db0nxP-CRTKA7ak9LCYucA/artifacts/public/build/target.test_packages.json --download-symbols true --cppunittest-suite=cppunittest --code-coverage" + ], + "env": { + "SCCACHE_DISABLE": "1", + "GECKO_HEAD_REV": "e31357c7759379d2279b6883cb09c91997bfaa5d", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.bz2\", \"extract\": true, \"task\": \"brd6yPH_TEegeE8bjBLsxQ\"}]", + "MOZ_FETCHES_DIR": "fetches", + "MOZ_AUTOMATION": "1" + }, + "mounts": [ + { + "directory": ".", + "content": { + "taskId": "Db0nxP-CRTKA7ak9LCYucA", + "artifact": "public/build/mozharness.zip" + }, + "format": "zip" + } + ] + }, + "metadata": { + "owner": "opoprus@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/e31357c7759379d2279b6883cb09c91997bfaa5d/taskcluster/ci/test", + "description": "CPP Unit Tests ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=e31357c7759379d2279b6883cb09c91997bfaa5d))", + "name": "test-windows10-64-ccov/debug-cppunit" + }, + "tags": { + "os": "windows", + "createdForUser": "opoprus@mozilla.com", + "worker-implementation": "generic-worker", + "kind": "test", + "label": "test-windows10-64-ccov/debug-cppunit" + }, + "extra": { + "index": { + "rank": 0 + }, + "parent": "Mu6w3n-dS9GOfrv6wGOtvg", + "chunks": { + "current": 1, + "total": 1 + }, + "suite": { + "flavor": "cppunittest", + "name": "cppunittest" + }, + "treeherder": { + "machine": { + "platform": "windows10-64-ccov" + }, + "tier": 2, + "symbol": "Cpp", + "jobKind": "test", + "collection": { + "debug": true + } + }, + "treeherder-platform": "windows10-64-ccov/debug" + } +} \ No newline at end of file diff --git a/bot/tests/fixtures/test-windows10-64-ccov/debug-mochitest-1.json b/bot/tests/fixtures/test-windows10-64-ccov/debug-mochitest-1.json new file mode 100644 index 000000000..9bb86314a --- /dev/null +++ b/bot/tests/fixtures/test-windows10-64-ccov/debug-mochitest-1.json @@ -0,0 +1,100 @@ +{ + "provisionerId": "aws-provisioner-v1", + "workerType": "gecko-t-win10-64", + "schedulerId": "gecko-level-3", + "taskGroupId": "Mu6w3n-dS9GOfrv6wGOtvg", + "dependencies": [ + "Db0nxP-CRTKA7ak9LCYucA", + "brd6yPH_TEegeE8bjBLsxQ" + ], + "requires": "all-completed", + "routes": [ + "tc-treeherder.v2.mozilla-central.e31357c7759379d2279b6883cb09c91997bfaa5d.35772", + "coalesce.v1.mozilla-central.f3031b7eecbe9114a96f" + ], + "priority": "medium", + "retries": 5, + "created": "2019-03-28T17:39:26.586Z", + "deadline": "2019-03-29T17:39:26.586Z", + "expires": "2020-03-27T17:39:26.586Z", + "scopes": [], + "payload": { + "supersederUrl": "https://coalesce.mozilla-releng.net/v1/list/3600/5/mozilla-central.f3031b7eecbe9114a96f", + "maxRunTime": 5400, + "artifacts": [ + { + "path": "logs", + "type": "directory", + "name": "public/logs" + }, + { + "path": "build/blobber_upload_dir", + "type": "directory", + "name": "public/test_info" + } + ], + "command": [ + "c:\\mozilla-build\\python\\python.exe -u mozharness\\scripts\\desktop_unittest.py --cfg mozharness\\configs\\unittests\\win_taskcluster_unittest.py --mochitest-suite=plain-chunked --code-coverage --e10s --installer-url https://queue.taskcluster.net/v1/task/Db0nxP-CRTKA7ak9LCYucA/artifacts/public/build/target.zip --test-packages-url https://queue.taskcluster.net/v1/task/Db0nxP-CRTKA7ak9LCYucA/artifacts/public/build/target.test_packages.json --download-symbols true --mochitest-suite=plain-chunked --code-coverage --e10s --total-chunk=10 --this-chunk=1" + ], + "env": { + "SCCACHE_DISABLE": "1", + "GECKO_HEAD_REV": "e31357c7759379d2279b6883cb09c91997bfaa5d", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.bz2\", \"extract\": true, \"task\": \"brd6yPH_TEegeE8bjBLsxQ\"}]", + "MOZ_FETCHES_DIR": "fetches", + "MOZ_AUTOMATION": "1" + }, + "mounts": [ + { + "directory": ".", + "content": { + "taskId": "Db0nxP-CRTKA7ak9LCYucA", + "artifact": "public/build/mozharness.zip" + }, + "format": "zip" + } + ] + }, + "metadata": { + "owner": "opoprus@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/e31357c7759379d2279b6883cb09c91997bfaa5d/taskcluster/ci/test", + "description": "Mochitest plain run ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=e31357c7759379d2279b6883cb09c91997bfaa5d))", + "name": "test-windows10-64-ccov/debug-mochitest-e10s-1" + }, + "tags": { + "kind": "test", + "worker-implementation": "generic-worker", + "createdForUser": "opoprus@mozilla.com", + "label": "test-windows10-64-ccov/debug-mochitest-e10s-1", + "test-type": "mochitest", + "os": "windows" + }, + "extra": { + "index": { + "rank": 0 + }, + "parent": "Mu6w3n-dS9GOfrv6wGOtvg", + "chunks": { + "current": 1, + "total": 10 + }, + "suite": { + "flavor": "plain-chunked", + "name": "mochitest" + }, + "treeherder": { + "jobKind": "test", + "groupSymbol": "M-e10s", + "collection": { + "debug": true + }, + "machine": { + "platform": "windows10-64-ccov" + }, + "groupName": "Mochitests with e10s", + "tier": 2, + "symbol": "1" + }, + "treeherder-platform": "windows10-64-ccov/debug" + } +} \ No newline at end of file diff --git a/bot/tests/fixtures/test-windows10-64-ccov/debug-mochitest-e10s-7.json b/bot/tests/fixtures/test-windows10-64-ccov/debug-mochitest-e10s-7.json new file mode 100644 index 000000000..82f634c1a --- /dev/null +++ b/bot/tests/fixtures/test-windows10-64-ccov/debug-mochitest-e10s-7.json @@ -0,0 +1,118 @@ +{ + "created": "2019-08-07T21:54:53.928Z", + "deadline": "2019-08-08T21:54:53.928Z", + "dependencies": [ + "bVpuwUYmQCqjPY-Ynu1YZQ", + "eA-zkasdQCmua27DPfzcZQ" + ], + "expires": "2020-08-06T21:54:53.928Z", + "extra": { + "chunks": { + "current": 7, + "total": 10 + }, + "index": { + "rank": 0 + }, + "parent": "PUZr6C8WR9Cmw3LeL9qotw", + "suite": "mochitest-plain-chunked", + "treeherder": { + "collection": { + "debug": true + }, + "groupName": "Mochitests", + "groupSymbol": "M", + "jobKind": "test", + "machine": { + "platform": "windows10-64-ccov" + }, + "symbol": "7", + "tier": 2 + }, + "treeherder-platform": "windows10-64-ccov/debug" + }, + "metadata": { + "description": "Mochitest plain run ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=3a71baea939144b4ec37805a932f0250c74986b1))", + "name": "test-windows10-64-ccov/debug-mochitest-e10s-7", + "owner": "shindli@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/3a71baea939144b4ec37805a932f0250c74986b1/taskcluster/ci/test" + }, + "payload": { + "artifacts": [ + { + "name": "public/logs", + "path": "logs", + "type": "directory" + }, + { + "name": "public/test_info", + "path": "build/blobber_upload_dir", + "type": "directory" + } + ], + "command": [ + "C:/mozilla-build/python3/python3.exe run-task -- c:\\mozilla-build\\python\\python.exe -u mozharness\\scripts\\desktop_unittest.py --cfg mozharness\\configs\\unittests\\win_unittest.py --mochitest-suite=mochitest-plain-chunked --code-coverage --setpref=media.peerconnection.mtransport_process=false --setpref=network.process.enabled=false --download-symbols true --mochitest-suite=mochitest-plain-chunked --code-coverage --setpref=media.peerconnection.mtransport_process=false --setpref=network.process.enabled=false --total-chunk=10 --this-chunk=7" + ], + "env": { + "EXTRA_MOZHARNESS_CONFIG": "{\"test_packages_url\": \"https://queue.taskcluster.net/v1/task/eA-zkasdQCmua27DPfzcZQ/artifacts/public/build/target.test_packages.json\", \"installer_url\": \"https://queue.taskcluster.net/v1/task/eA-zkasdQCmua27DPfzcZQ/artifacts/public/build/target.zip\"}", + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "GECKO_HEAD_REV": "3a71baea939144b4ec37805a932f0250c74986b1", + "MOZ_AUTOMATION": "1", + "MOZ_FETCHES": "[{\"artifact\": \"public/build/grcov.tar.bz2\", \"extract\": true, \"task\": \"bVpuwUYmQCqjPY-Ynu1YZQ\"}]", + "MOZ_FETCHES_DIR": "fetches", + "MOZ_SCM_LEVEL": "3", + "SCCACHE_DISABLE": "1" + }, + "maxRunTime": 5400, + "mounts": [ + { + "content": { + "artifact": "public/build/mozharness.zip", + "taskId": "eA-zkasdQCmua27DPfzcZQ" + }, + "directory": ".", + "format": "zip" + }, + { + "content": { + "url": "https://hg.mozilla.org/mozilla-central/raw-file/3a71baea939144b4ec37805a932f0250c74986b1/taskcluster/scripts/run-task" + }, + "file": "./run-task" + }, + { + "content": { + "url": "https://hg.mozilla.org/mozilla-central/raw-file/3a71baea939144b4ec37805a932f0250c74986b1/taskcluster/scripts/misc/fetch-content" + }, + "file": "./fetch-content" + } + ], + "onExitStatus": { + "retry": [ + 1073807364, + 3221225786 + ] + }, + "supersederUrl": "https://coalesce.mozilla-releng.net/v1/list/3600/5/mozilla-central.7b8ad30082b7aa4bcac6" + }, + "priority": "medium", + "provisionerId": "aws-provisioner-v1", + "requires": "all-completed", + "retries": 5, + "routes": [ + "tc-treeherder.v2.mozilla-central.3a71baea939144b4ec37805a932f0250c74986b1.36406", + "coalesce.v1.mozilla-central.7b8ad30082b7aa4bcac6" + ], + "schedulerId": "gecko-level-3", + "scopes": [], + "tags": { + "createdForUser": "shindli@mozilla.com", + "kind": "test", + "label": "test-windows10-64-ccov/debug-mochitest-e10s-7", + "os": "windows", + "retrigger": "true", + "test-type": "mochitest", + "worker-implementation": "generic-worker" + }, + "taskGroupId": "PUZr6C8WR9Cmw3LeL9qotw", + "workerType": "gecko-t-win10-64" +} \ No newline at end of file diff --git a/bot/tests/fixtures/test-windows10-64/debug-cppunit.json b/bot/tests/fixtures/test-windows10-64/debug-cppunit.json new file mode 100644 index 000000000..2f88b3416 --- /dev/null +++ b/bot/tests/fixtures/test-windows10-64/debug-cppunit.json @@ -0,0 +1,94 @@ +{ + "provisionerId": "aws-provisioner-v1", + "workerType": "gecko-t-win10-64", + "schedulerId": "gecko-level-3", + "taskGroupId": "Mu6w3n-dS9GOfrv6wGOtvg", + "dependencies": [ + "W7r-_k6BRti6V69f6PVFQA" + ], + "requires": "all-completed", + "routes": [ + "tc-treeherder.v2.mozilla-central.e31357c7759379d2279b6883cb09c91997bfaa5d.35772", + "coalesce.v1.mozilla-central.e97a7cee04fa0f3b4f7d" + ], + "priority": "medium", + "retries": 5, + "created": "2019-03-28T17:40:03.103Z", + "deadline": "2019-03-29T17:40:03.103Z", + "expires": "2020-03-27T17:40:03.103Z", + "scopes": [], + "payload": { + "supersederUrl": "https://coalesce.mozilla-releng.net/v1/list/3600/5/mozilla-central.e97a7cee04fa0f3b4f7d", + "maxRunTime": 3600, + "artifacts": [ + { + "path": "logs", + "type": "directory", + "name": "public/logs" + }, + { + "path": "build/blobber_upload_dir", + "type": "directory", + "name": "public/test_info" + } + ], + "command": [ + "c:\\mozilla-build\\python\\python.exe -u mozharness\\scripts\\desktop_unittest.py --cfg mozharness\\configs\\unittests\\win_taskcluster_unittest.py --cppunittest-suite=cppunittest --installer-url https://queue.taskcluster.net/v1/task/W7r-_k6BRti6V69f6PVFQA/artifacts/public/build/target.zip --test-packages-url https://queue.taskcluster.net/v1/task/W7r-_k6BRti6V69f6PVFQA/artifacts/public/build/target.test_packages.json --download-symbols true --cppunittest-suite=cppunittest" + ], + "env": { + "GECKO_HEAD_REPOSITORY": "https://hg.mozilla.org/mozilla-central", + "MOZ_AUTOMATION": "1", + "SCCACHE_DISABLE": "1", + "GECKO_HEAD_REV": "e31357c7759379d2279b6883cb09c91997bfaa5d" + }, + "mounts": [ + { + "directory": ".", + "content": { + "taskId": "W7r-_k6BRti6V69f6PVFQA", + "artifact": "public/build/mozharness.zip" + }, + "format": "zip" + } + ] + }, + "metadata": { + "owner": "opoprus@mozilla.com", + "source": "https://hg.mozilla.org/mozilla-central/file/e31357c7759379d2279b6883cb09c91997bfaa5d/taskcluster/ci/test", + "description": "CPP Unit Tests ([Treeherder push](https://treeherder.mozilla.org/#/jobs?repo=mozilla-central&revision=e31357c7759379d2279b6883cb09c91997bfaa5d))", + "name": "test-windows10-64/debug-cppunit" + }, + "tags": { + "os": "windows", + "createdForUser": "opoprus@mozilla.com", + "worker-implementation": "generic-worker", + "kind": "test", + "label": "test-windows10-64/debug-cppunit" + }, + "extra": { + "index": { + "rank": 1553794301 + }, + "parent": "Mu6w3n-dS9GOfrv6wGOtvg", + "chunks": { + "current": 1, + "total": 1 + }, + "suite": { + "flavor": "cppunittest", + "name": "cppunittest" + }, + "treeherder": { + "machine": { + "platform": "windows10-64" + }, + "tier": 1, + "symbol": "Cpp", + "jobKind": "test", + "collection": { + "debug": true + } + }, + "treeherder-platform": "windows10-64/debug" + } +} \ No newline at end of file diff --git a/bot/tests/fixtures/test_task_from_group.json b/bot/tests/fixtures/test_task_from_group.json index bda275590..3bf9d70cb 100644 --- a/bot/tests/fixtures/test_task_from_group.json +++ b/bot/tests/fixtures/test_task_from_group.json @@ -121,10 +121,7 @@ "current": 4, "total": 8 }, - "suite": { - "flavor": "mochitest-devtools-chrome-chunked", - "name": "mochitest" - }, + "suite": "mochitest-devtools-chrome", "treeherder": { "jobKind": "test", "groupSymbol": "M-e10s", diff --git a/bot/tests/test_artifacts.py b/bot/tests/test_artifacts.py index 26e993fc8..d03aa4a06 100644 --- a/bot/tests/test_artifacts.py +++ b/bot/tests/test_artifacts.py @@ -142,9 +142,18 @@ def _group_tasks(): def build_task(task_state): task_name = task_state[0] state = task_state[1] + platform, test = task_name.split("/") + suite = test.rstrip("debug-") + platform = platform.lstrip("test-").rstrip("-ccov") + print(suite, platform) return { "status": {"taskId": task_name + "-" + state, "state": state}, - "task": {"metadata": {"name": task_name}}, + "task": { + "metadata": {"name": task_name}, + "env": {}, + "extra": {"suite": suite}, + "tags": {"os": platform}, + }, } # Generate all possible permutations of task_name - state. diff --git a/bot/tests/test_chunk_mapping.py b/bot/tests/test_chunk_mapping.py index a2827883c..3ffb0bc21 100644 --- a/bot/tests/test_chunk_mapping.py +++ b/bot/tests/test_chunk_mapping.py @@ -68,7 +68,9 @@ def test_zero_coverage(tmpdir, fake_artifacts_handler, fake_hg_repo_with_content def request_callback(request): payload = json.loads(request.body.decode("utf-8")) - print(payload) + from pprint import pprint + + pprint(payload) if payload["from"] == "coverage": if "groupby" in payload: diff --git a/bot/tests/test_taskcluster.py b/bot/tests/test_taskcluster.py index 43eee4986..86be313aa 100644 --- a/bot/tests/test_taskcluster.py +++ b/bot/tests/test_taskcluster.py @@ -1,5 +1,6 @@ # -*- coding: utf-8 -*- +import json import os from unittest import mock from zipfile import BadZipFile @@ -9,6 +10,7 @@ import responses from code_coverage_bot import taskcluster +from conftest import FIXTURES_DIR @responses.activate @@ -135,42 +137,32 @@ def test_get_tasks_in_group(GROUP_TASKS_1, GROUP_TASKS_2): ) -def test_is_coverage_task(): - assert taskcluster.is_coverage_task( - {"task": {"metadata": {"name": "test-linux64-ccov/debug-mochitest-1"}}} - ) - - assert not taskcluster.is_coverage_task( - {"task": {"metadata": {"name": "test-linux64/debug-mochitest-1"}}} - ) - - assert taskcluster.is_coverage_task( - {"task": {"metadata": {"name": "test-windows10-64-ccov/debug-cppunit"}}} - ) - - assert not taskcluster.is_coverage_task( - {"task": {"metadata": {"name": "test-windows10-64/debug-cppunit"}}} - ) - - assert taskcluster.is_coverage_task( - {"task": {"metadata": {"name": "build-win64-ccov/debug"}}} - ) - - assert not taskcluster.is_coverage_task( - {"task": {"metadata": {"name": "build-win64/debug"}}} - ) - - assert taskcluster.is_coverage_task( - {"task": {"metadata": {"name": "build-linux64-ccov/debug"}}} - ) - - assert not taskcluster.is_coverage_task( - {"task": {"metadata": {"name": "build-linux64/debug"}}} - ) - - -def test_get_chunk(): - tests = [ +@pytest.mark.parametrize( + "task_name, expected", + [ + ("test-linux64-ccov/debug-mochitest-1", True), + ("test-linux64-ccov/debug-mochitest-e10s-7", True), + ("test-linux64-ccov/debug-cppunit", True), + ("test-linux64-ccov/debug-firefox-ui-functional-remote-e10s", True), + ("test-windows10-64-ccov/debug-mochitest-1", True), + ("test-windows10-64-ccov/debug-mochitest-e10s-7", True), + ("test-windows10-64-ccov/debug-cppunit", True), + ("build-linux64-ccov/debug", True), + ("build-android-test-ccov/opt", True), + ("build-win64-ccov/debug", True), + ("test-linux64/debug-mochitest-1", False), + ("test-windows10-64/debug-cppunit", False), + ("build-win64/debug", False), + ], +) +def test_is_coverage_task(task_name, expected): + task = json.load(open(os.path.join(FIXTURES_DIR, f"{task_name}.json"))) + assert taskcluster.is_coverage_task(task) is expected + + +@pytest.mark.parametrize( + "task_name, expected", + [ ("test-linux64-ccov/debug-mochitest-1", "mochitest-1"), ("test-linux64-ccov/debug-mochitest-e10s-7", "mochitest-7"), ("test-linux64-ccov/debug-cppunit", "cppunit"), @@ -184,37 +176,90 @@ def test_get_chunk(): ("build-linux64-ccov/debug", "build"), ("build-android-test-ccov/opt", "build"), ("build-win64-ccov/debug", "build"), - ] - - for (name, chunk) in tests: - assert taskcluster.get_chunk(name) == chunk + ], +) +def test_name_to_chunk(task_name, expected): + assert taskcluster.name_to_chunk(task_name) == expected -def test_get_suite(): - tests = [ +@pytest.mark.parametrize( + "chunk, expected", + [ ("mochitest-1", "mochitest"), ("mochitest-7", "mochitest"), ("cppunit", "cppunit"), ("firefox-ui-functional-remote", "firefox-ui-functional-remote"), ("build", "build"), - ] + ], +) +def test_chunk_to_suite(chunk, expected): + assert taskcluster.chunk_to_suite(chunk) == expected - for (chunk, suite) in tests: - assert taskcluster.get_suite(chunk) == suite +@pytest.mark.parametrize( + "task_name, expected", + [ + ("test-linux64-ccov/debug-mochitest-1", "mochitest-1"), + ("test-linux64-ccov/debug-mochitest-e10s-7", "mochitest-plain-chunked-7"), + ("test-linux64-ccov/debug-cppunit", "cppunittest-1"), + ( + "test-linux64-ccov/debug-firefox-ui-functional-remote-e10s", + "firefox-ui-functional-remote-1", + ), + ("test-windows10-64-ccov/debug-mochitest-1", "mochitest-1"), + ("test-windows10-64-ccov/debug-mochitest-e10s-7", "mochitest-plain-chunked-7"), + ("test-windows10-64-ccov/debug-cppunit", "cppunittest-1"), + ("build-linux64-ccov/debug", "build"), + ("build-android-test-ccov/opt", "build"), + ("build-win64-ccov/debug", "build"), + ], +) +def test_get_chunk(task_name, expected): + task = json.load(open(os.path.join(FIXTURES_DIR, f"{task_name}.json"))) + assert taskcluster.get_chunk(task) == expected + + +@pytest.mark.parametrize( + "task_name, expected", + [ + ("test-linux64-ccov/debug-mochitest-1", "mochitest"), + ("test-linux64-ccov/debug-mochitest-e10s-7", "mochitest-plain-chunked"), + ("test-linux64-ccov/debug-cppunit", "cppunittest"), + ( + "test-linux64-ccov/debug-firefox-ui-functional-remote-e10s", + "firefox-ui-functional-remote", + ), + ("test-windows10-64-ccov/debug-mochitest-1", "mochitest"), + ("test-windows10-64-ccov/debug-mochitest-e10s-7", "mochitest-plain-chunked"), + ("test-windows10-64-ccov/debug-cppunit", "cppunittest"), + ("build-linux64-ccov/debug", "build"), + ("build-android-test-ccov/opt", "build"), + ("build-win64-ccov/debug", "build"), + ], +) +def test_get_suite(task_name, expected): + task = json.load(open(os.path.join(FIXTURES_DIR, f"{task_name}.json"))) + assert taskcluster.get_suite(task) == expected -def test_get_platform(): - tests = [ + +@pytest.mark.parametrize( + "task_name, expected", + [ ("test-linux64-ccov/debug-mochitest-1", "linux"), + ("test-linux64-ccov/debug-mochitest-e10s-7", "linux"), + ("test-linux64-ccov/debug-cppunit", "linux"), + ("test-linux64-ccov/debug-firefox-ui-functional-remote-e10s", "linux"), ("test-windows10-64-ccov/debug-mochitest-1", "windows"), + ("test-windows10-64-ccov/debug-mochitest-e10s-7", "windows"), + ("test-windows10-64-ccov/debug-cppunit", "windows"), ("build-linux64-ccov/debug", "linux"), + ("build-android-test-ccov/opt", "android"), ("build-win64-ccov/debug", "windows"), - ("build-android-test-ccov/opt", "android-test"), - ("test-android-em-4.3-arm7-api-16-ccov/debug-robocop-2", "android-emulator"), - ] - - for (name, platform) in tests: - assert taskcluster.get_platform(name) == platform + ], +) +def test_get_platform(task_name, expected): + task = json.load(open(os.path.join(FIXTURES_DIR, f"{task_name}.json"))) + assert taskcluster.get_platform(task) == expected @mock.patch("time.sleep")