@hominis/fireforge 0.46.0 → 0.46.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +381 -498
- package/dist/bin/fireforge.d.ts +1 -1
- package/dist/bin/fireforge.js +17 -17
- package/dist/build-info.json +4 -4
- package/dist/src/cli-usage-error.d.ts +9 -9
- package/dist/src/cli-usage-error.js +12 -12
- package/dist/src/cli.d.ts +3 -2
- package/dist/src/cli.js +29 -28
- package/dist/src/commands/bootstrap-checks.js +2 -1
- package/dist/src/commands/bootstrap.js +2 -2
- package/dist/src/commands/build.js +12 -11
- package/dist/src/commands/config.js +9 -9
- package/dist/src/commands/destructive-decision.d.ts +4 -4
- package/dist/src/commands/destructive-decision.js +4 -4
- package/dist/src/commands/discard.js +5 -5
- package/dist/src/commands/doctor-check-core.d.ts +4 -4
- package/dist/src/commands/doctor-external-toolchains.js +2 -2
- package/dist/src/commands/doctor-furnace-config-sync.d.ts +2 -2
- package/dist/src/commands/doctor-furnace-config-sync.js +20 -20
- package/dist/src/commands/doctor-furnace-jar.d.ts +1 -1
- package/dist/src/commands/doctor-furnace-jar.js +1 -1
- package/dist/src/commands/doctor-furnace.js +22 -22
- package/dist/src/commands/doctor-orphaned-harness.d.ts +10 -11
- package/dist/src/commands/doctor-orphaned-harness.js +10 -11
- package/dist/src/commands/doctor-patch-manifest.d.ts +2 -1
- package/dist/src/commands/doctor-patch-manifest.js +7 -6
- package/dist/src/commands/doctor-post-rebase-audit.js +2 -2
- package/dist/src/commands/doctor-source-pin.d.ts +12 -12
- package/dist/src/commands/doctor-source-pin.js +14 -14
- package/dist/src/commands/doctor-working-tree.d.ts +3 -3
- package/dist/src/commands/doctor-working-tree.js +3 -3
- package/dist/src/commands/doctor.d.ts +2 -2
- package/dist/src/commands/doctor.js +9 -9
- package/dist/src/commands/download.js +15 -13
- package/dist/src/commands/export-all.js +8 -8
- package/dist/src/commands/export-flow.d.ts +5 -5
- package/dist/src/commands/export-flow.js +14 -14
- package/dist/src/commands/export-placement-conflicts.d.ts +3 -3
- package/dist/src/commands/export-placement-conflicts.js +9 -9
- package/dist/src/commands/export-placement-gate.d.ts +2 -2
- package/dist/src/commands/export-placement-gate.js +5 -5
- package/dist/src/commands/export-placement-policy.d.ts +1 -1
- package/dist/src/commands/export-placement-policy.js +1 -1
- package/dist/src/commands/export-shared.d.ts +10 -10
- package/dist/src/commands/export-shared.js +13 -13
- package/dist/src/commands/export.js +4 -4
- package/dist/src/commands/furnace/apply.js +16 -16
- package/dist/src/commands/furnace/chrome-doc-remove.d.ts +1 -1
- package/dist/src/commands/furnace/chrome-doc-remove.js +1 -1
- package/dist/src/commands/furnace/chrome-doc-templates.d.ts +14 -14
- package/dist/src/commands/furnace/chrome-doc-templates.js +17 -17
- package/dist/src/commands/furnace/chrome-doc-tests.d.ts +2 -2
- package/dist/src/commands/furnace/chrome-doc-tests.js +4 -4
- package/dist/src/commands/furnace/chrome-doc.d.ts +8 -8
- package/dist/src/commands/furnace/chrome-doc.js +18 -18
- package/dist/src/commands/furnace/create-browser-test.d.ts +1 -1
- package/dist/src/commands/furnace/create-browser-test.js +4 -4
- package/dist/src/commands/furnace/create-dry-run.d.ts +4 -4
- package/dist/src/commands/furnace/create-dry-run.js +4 -4
- package/dist/src/commands/furnace/create-features.d.ts +2 -2
- package/dist/src/commands/furnace/create-features.js +2 -2
- package/dist/src/commands/furnace/create-mochikit.d.ts +4 -4
- package/dist/src/commands/furnace/create-mochikit.js +7 -7
- package/dist/src/commands/furnace/create-templates.d.ts +14 -14
- package/dist/src/commands/furnace/create-templates.js +18 -18
- package/dist/src/commands/furnace/create-xpcshell.d.ts +5 -5
- package/dist/src/commands/furnace/create-xpcshell.js +8 -8
- package/dist/src/commands/furnace/create.d.ts +1 -1
- package/dist/src/commands/furnace/create.js +10 -10
- package/dist/src/commands/furnace/deploy.js +4 -4
- package/dist/src/commands/furnace/diff.js +7 -7
- package/dist/src/commands/furnace/index.js +1 -1
- package/dist/src/commands/furnace/init.js +15 -15
- package/dist/src/commands/furnace/list.js +2 -2
- package/dist/src/commands/furnace/override.d.ts +1 -1
- package/dist/src/commands/furnace/override.js +15 -15
- package/dist/src/commands/furnace/preview.js +17 -17
- package/dist/src/commands/furnace/refresh.js +6 -6
- package/dist/src/commands/furnace/remove-mutations.d.ts +3 -3
- package/dist/src/commands/furnace/remove-mutations.js +19 -18
- package/dist/src/commands/furnace/remove-state.d.ts +1 -1
- package/dist/src/commands/furnace/remove-state.js +1 -1
- package/dist/src/commands/furnace/remove.js +2 -2
- package/dist/src/commands/furnace/rename-browser-test.js +9 -8
- package/dist/src/commands/furnace/rename-xpcshell.d.ts +2 -2
- package/dist/src/commands/furnace/rename-xpcshell.js +3 -3
- package/dist/src/commands/furnace/rename.js +9 -9
- package/dist/src/commands/furnace/scan.js +3 -3
- package/dist/src/commands/furnace/status.js +7 -7
- package/dist/src/commands/furnace/sync.js +6 -6
- package/dist/src/commands/furnace/test-file-name.d.ts +2 -2
- package/dist/src/commands/furnace/test-file-name.js +2 -2
- package/dist/src/commands/furnace/validate.js +11 -12
- package/dist/src/commands/import.js +20 -20
- package/dist/src/commands/lint-per-patch.js +8 -8
- package/dist/src/commands/lint-per-run-checkjs.d.ts +12 -13
- package/dist/src/commands/lint-per-run-checkjs.js +14 -15
- package/dist/src/commands/lint-report.d.ts +3 -3
- package/dist/src/commands/lint-report.js +4 -4
- package/dist/src/commands/lint.d.ts +3 -3
- package/dist/src/commands/lint.js +35 -35
- package/dist/src/commands/manifest.d.ts +4 -4
- package/dist/src/commands/package.js +2 -2
- package/dist/src/commands/patch/compact.d.ts +2 -2
- package/dist/src/commands/patch/compact.js +8 -8
- package/dist/src/commands/patch/delete.d.ts +1 -1
- package/dist/src/commands/patch/delete.js +8 -8
- package/dist/src/commands/patch/lint-ignore.d.ts +3 -4
- package/dist/src/commands/patch/lint-ignore.js +14 -15
- package/dist/src/commands/patch/move-files-create.d.ts +2 -2
- package/dist/src/commands/patch/move-files-create.js +5 -5
- package/dist/src/commands/patch/move-files-into.d.ts +2 -2
- package/dist/src/commands/patch/move-files-into.js +3 -3
- package/dist/src/commands/patch/move-files.js +1 -1
- package/dist/src/commands/patch/patch-context.d.ts +1 -1
- package/dist/src/commands/patch/rename.d.ts +4 -4
- package/dist/src/commands/patch/rename.js +8 -8
- package/dist/src/commands/patch/reorder.js +10 -10
- package/dist/src/commands/patch/split-plan.d.ts +3 -3
- package/dist/src/commands/patch/split-plan.js +6 -5
- package/dist/src/commands/patch/split.d.ts +2 -2
- package/dist/src/commands/patch/split.js +5 -5
- package/dist/src/commands/patch/staged-dependency-validate.d.ts +1 -1
- package/dist/src/commands/patch/staged-dependency-validate.js +3 -3
- package/dist/src/commands/patch/staged-dependency.d.ts +1 -1
- package/dist/src/commands/patch/staged-dependency.js +6 -6
- package/dist/src/commands/patch/tier.d.ts +2 -2
- package/dist/src/commands/patch/tier.js +5 -5
- package/dist/src/commands/patch-rename-map.d.ts +1 -1
- package/dist/src/commands/patch-rename-map.js +1 -1
- package/dist/src/commands/pending-resolution.d.ts +5 -5
- package/dist/src/commands/pending-resolution.js +5 -5
- package/dist/src/commands/re-export-adjacent.d.ts +3 -3
- package/dist/src/commands/re-export-adjacent.js +8 -8
- package/dist/src/commands/re-export-bulk-scan.d.ts +3 -3
- package/dist/src/commands/re-export-bulk-scan.js +17 -17
- package/dist/src/commands/re-export-drift.d.ts +10 -10
- package/dist/src/commands/re-export-drift.js +29 -29
- package/dist/src/commands/re-export-files.js +14 -15
- package/dist/src/commands/re-export-lint.d.ts +26 -26
- package/dist/src/commands/re-export-lint.js +27 -27
- package/dist/src/commands/re-export-options.d.ts +1 -1
- package/dist/src/commands/re-export-options.js +1 -1
- package/dist/src/commands/re-export-register.d.ts +1 -1
- package/dist/src/commands/re-export-register.js +1 -1
- package/dist/src/commands/re-export-scan.d.ts +1 -1
- package/dist/src/commands/re-export-scan.js +7 -7
- package/dist/src/commands/re-export-single.d.ts +1 -1
- package/dist/src/commands/re-export-single.js +20 -20
- package/dist/src/commands/re-export.js +7 -6
- package/dist/src/commands/rebase/abort.js +6 -6
- package/dist/src/commands/rebase/continue.js +8 -7
- package/dist/src/commands/rebase/index.d.ts +1 -1
- package/dist/src/commands/rebase/index.js +3 -3
- package/dist/src/commands/rebase/patch-loop.js +18 -17
- package/dist/src/commands/register.js +5 -5
- package/dist/src/commands/reset.js +1 -1
- package/dist/src/commands/resolve.d.ts +2 -2
- package/dist/src/commands/resolve.js +3 -3
- package/dist/src/commands/run.js +26 -26
- package/dist/src/commands/setup-support.js +4 -4
- package/dist/src/commands/setup.js +1 -1
- package/dist/src/commands/source.js +1 -1
- package/dist/src/commands/status-check.d.ts +3 -3
- package/dist/src/commands/status-check.js +4 -4
- package/dist/src/commands/status-json.d.ts +14 -13
- package/dist/src/commands/status-json.js +9 -8
- package/dist/src/commands/status-output.d.ts +3 -3
- package/dist/src/commands/status-output.js +3 -3
- package/dist/src/commands/status-ownership.d.ts +3 -3
- package/dist/src/commands/status-ownership.js +3 -3
- package/dist/src/commands/status.js +22 -22
- package/dist/src/commands/test-build-phase.d.ts +1 -1
- package/dist/src/commands/test-build-phase.js +17 -17
- package/dist/src/commands/test-diagnose.d.ts +1 -1
- package/dist/src/commands/test-diagnose.js +20 -20
- package/dist/src/commands/test-modes.d.ts +2 -2
- package/dist/src/commands/test-modes.js +4 -4
- package/dist/src/commands/test-run.d.ts +11 -11
- package/dist/src/commands/test-run.js +15 -15
- package/dist/src/commands/test-stale-gate.d.ts +12 -12
- package/dist/src/commands/test-stale-gate.js +13 -13
- package/dist/src/commands/test-verdict.d.ts +6 -6
- package/dist/src/commands/test-verdict.js +11 -11
- package/dist/src/commands/test.d.ts +3 -3
- package/dist/src/commands/test.js +36 -36
- package/dist/src/commands/token-coverage.js +3 -3
- package/dist/src/commands/token-list.js +5 -5
- package/dist/src/commands/token.js +9 -9
- package/dist/src/commands/tree.js +19 -19
- package/dist/src/commands/typecheck.d.ts +6 -6
- package/dist/src/commands/typecheck.js +7 -7
- package/dist/src/commands/verify.d.ts +3 -3
- package/dist/src/commands/verify.js +10 -10
- package/dist/src/commands/watch.js +11 -11
- package/dist/src/commands/wire.js +13 -13
- package/dist/src/core/ast-utils.d.ts +7 -7
- package/dist/src/core/ast-utils.js +8 -8
- package/dist/src/core/branding.d.ts +5 -5
- package/dist/src/core/branding.js +3 -3
- package/dist/src/core/browser-wire.d.ts +1 -1
- package/dist/src/core/browser-wire.js +4 -4
- package/dist/src/core/build-audit-platform.d.ts +6 -6
- package/dist/src/core/build-audit-platform.js +26 -26
- package/dist/src/core/build-audit-registration.d.ts +5 -5
- package/dist/src/core/build-audit-registration.js +7 -7
- package/dist/src/core/build-audit-resolve.d.ts +5 -5
- package/dist/src/core/build-audit-resolve.js +6 -6
- package/dist/src/core/build-audit-skip.d.ts +8 -8
- package/dist/src/core/build-audit-skip.js +12 -12
- package/dist/src/core/build-audit-transforms.d.ts +2 -2
- package/dist/src/core/build-audit-transforms.js +3 -3
- package/dist/src/core/build-audit.d.ts +8 -8
- package/dist/src/core/build-audit.js +39 -37
- package/dist/src/core/build-baseline-types.d.ts +19 -18
- package/dist/src/core/build-baseline-types.js +1 -1
- package/dist/src/core/build-baseline.d.ts +8 -8
- package/dist/src/core/build-baseline.js +14 -14
- package/dist/src/core/build-jar-escalation.d.ts +8 -8
- package/dist/src/core/build-jar-escalation.js +15 -15
- package/dist/src/core/build-overwrite-guard.d.ts +4 -4
- package/dist/src/core/build-overwrite-guard.js +13 -13
- package/dist/src/core/build-prepare.d.ts +4 -4
- package/dist/src/core/build-prepare.js +16 -15
- package/dist/src/core/config-mutate.js +4 -4
- package/dist/src/core/config-state.js +2 -2
- package/dist/src/core/config-validate-build-audit.js +3 -3
- package/dist/src/core/config-validate-file-size.d.ts +1 -1
- package/dist/src/core/config-validate-file-size.js +2 -2
- package/dist/src/core/config-validate.js +8 -9
- package/dist/src/core/config.d.ts +10 -10
- package/dist/src/core/config.js +10 -10
- package/dist/src/core/coverage-extend.d.ts +16 -16
- package/dist/src/core/coverage-extend.js +16 -16
- package/dist/src/core/destructive.d.ts +14 -14
- package/dist/src/core/destructive.js +9 -9
- package/dist/src/core/diff-hunks.d.ts +2 -2
- package/dist/src/core/diff-hunks.js +7 -7
- package/dist/src/core/discard-baseline.d.ts +10 -10
- package/dist/src/core/discard-baseline.js +15 -16
- package/dist/src/core/display-state.d.ts +11 -11
- package/dist/src/core/display-state.js +12 -12
- package/dist/src/core/engine-changes.d.ts +2 -2
- package/dist/src/core/engine-changes.js +2 -2
- package/dist/src/core/engine-precondition.d.ts +4 -4
- package/dist/src/core/engine-precondition.js +2 -2
- package/dist/src/core/engine-session-lock.d.ts +18 -18
- package/dist/src/core/engine-session-lock.js +37 -37
- package/dist/src/core/export-moved-code-shape.d.ts +7 -7
- package/dist/src/core/export-moved-code-shape.js +8 -8
- package/dist/src/core/file-lock-owner.d.ts +11 -11
- package/dist/src/core/file-lock-owner.js +18 -18
- package/dist/src/core/file-lock.d.ts +12 -12
- package/dist/src/core/file-lock.js +52 -39
- package/dist/src/core/firefox-cache.d.ts +1 -1
- package/dist/src/core/firefox-cache.js +10 -10
- package/dist/src/core/firefox-download.d.ts +3 -3
- package/dist/src/core/firefox-download.js +6 -6
- package/dist/src/core/firefox-extract.d.ts +2 -2
- package/dist/src/core/firefox-extract.js +13 -13
- package/dist/src/core/firefox.d.ts +5 -5
- package/dist/src/core/firefox.js +8 -8
- package/dist/src/core/furnace-apply-dry-run.js +1 -1
- package/dist/src/core/furnace-apply-ftl.d.ts +5 -5
- package/dist/src/core/furnace-apply-ftl.js +8 -8
- package/dist/src/core/furnace-apply-helpers.d.ts +9 -9
- package/dist/src/core/furnace-apply-helpers.js +21 -21
- package/dist/src/core/furnace-apply-output.js +1 -1
- package/dist/src/core/furnace-apply-overwrite-warn.d.ts +9 -9
- package/dist/src/core/furnace-apply-overwrite-warn.js +9 -9
- package/dist/src/core/furnace-apply-undeploy-actions.d.ts +1 -1
- package/dist/src/core/furnace-apply-undeploy-actions.js +1 -1
- package/dist/src/core/furnace-apply.d.ts +3 -3
- package/dist/src/core/furnace-apply.js +22 -21
- package/dist/src/core/furnace-checksum-utils.d.ts +5 -5
- package/dist/src/core/furnace-checksum-utils.js +5 -5
- package/dist/src/core/furnace-config-custom.d.ts +1 -1
- package/dist/src/core/furnace-config-custom.js +2 -2
- package/dist/src/core/furnace-config-order.js +1 -1
- package/dist/src/core/furnace-config-tokens.d.ts +3 -3
- package/dist/src/core/furnace-config-tokens.js +3 -3
- package/dist/src/core/furnace-config-validate.js +2 -2
- package/dist/src/core/furnace-config.d.ts +4 -4
- package/dist/src/core/furnace-config.js +18 -18
- package/dist/src/core/furnace-constants.d.ts +6 -6
- package/dist/src/core/furnace-constants.js +6 -6
- package/dist/src/core/furnace-css-fragments.d.ts +6 -6
- package/dist/src/core/furnace-css-fragments.js +11 -11
- package/dist/src/core/furnace-dir-entry.d.ts +1 -1
- package/dist/src/core/furnace-dir-entry.js +1 -1
- package/dist/src/core/furnace-jsconfig.d.ts +7 -7
- package/dist/src/core/furnace-jsconfig.js +22 -20
- package/dist/src/core/furnace-operation.d.ts +21 -20
- package/dist/src/core/furnace-operation.js +36 -34
- package/dist/src/core/furnace-precondition.d.ts +10 -10
- package/dist/src/core/furnace-precondition.js +8 -8
- package/dist/src/core/furnace-refresh.js +2 -2
- package/dist/src/core/furnace-registration-ast.d.ts +2 -2
- package/dist/src/core/furnace-registration-ast.js +9 -9
- package/dist/src/core/furnace-registration-remove.d.ts +4 -4
- package/dist/src/core/furnace-registration-remove.js +6 -6
- package/dist/src/core/furnace-registration-validate.d.ts +2 -2
- package/dist/src/core/furnace-registration-validate.js +2 -2
- package/dist/src/core/furnace-registration.d.ts +5 -5
- package/dist/src/core/furnace-registration.js +7 -7
- package/dist/src/core/furnace-rollback.d.ts +1 -1
- package/dist/src/core/furnace-rollback.js +5 -5
- package/dist/src/core/furnace-stale-export.d.ts +17 -16
- package/dist/src/core/furnace-stale-export.js +16 -15
- package/dist/src/core/furnace-staleness.d.ts +2 -2
- package/dist/src/core/furnace-staleness.js +2 -2
- package/dist/src/core/furnace-state-persist.d.ts +10 -10
- package/dist/src/core/furnace-state-persist.js +10 -10
- package/dist/src/core/furnace-step-errors.d.ts +6 -6
- package/dist/src/core/furnace-step-errors.js +6 -6
- package/dist/src/core/furnace-validate-accessibility.js +14 -14
- package/dist/src/core/furnace-validate-compatibility.js +9 -9
- package/dist/src/core/furnace-validate-registration.d.ts +2 -2
- package/dist/src/core/furnace-validate-registration.js +13 -13
- package/dist/src/core/furnace-validate-structure.d.ts +1 -1
- package/dist/src/core/furnace-validate-structure.js +4 -4
- package/dist/src/core/furnace-validate.js +9 -9
- package/dist/src/core/furnace-version-drift.d.ts +5 -5
- package/dist/src/core/furnace-version-drift.js +5 -5
- package/dist/src/core/git-base.d.ts +4 -4
- package/dist/src/core/git-base.js +9 -9
- package/dist/src/core/git-diff-new-file.d.ts +4 -4
- package/dist/src/core/git-diff-new-file.js +8 -8
- package/dist/src/core/git-diff.d.ts +4 -4
- package/dist/src/core/git-diff.js +35 -34
- package/dist/src/core/git-file-ops.d.ts +6 -6
- package/dist/src/core/git-file-ops.js +7 -7
- package/dist/src/core/git-readonly-index.d.ts +12 -12
- package/dist/src/core/git-readonly-index.js +12 -12
- package/dist/src/core/git-status.d.ts +4 -4
- package/dist/src/core/git-status.js +4 -4
- package/dist/src/core/git.d.ts +3 -3
- package/dist/src/core/git.js +14 -14
- package/dist/src/core/harness-orphans.d.ts +17 -17
- package/dist/src/core/harness-orphans.js +20 -20
- package/dist/src/core/history-log.d.ts +3 -3
- package/dist/src/core/history-log.js +3 -3
- package/dist/src/core/license-headers.d.ts +19 -18
- package/dist/src/core/license-headers.js +29 -28
- package/dist/src/core/mach-build-artifacts.d.ts +21 -21
- package/dist/src/core/mach-build-artifacts.js +23 -23
- package/dist/src/core/mach-error-hints.d.ts +5 -5
- package/dist/src/core/mach-error-hints.js +13 -13
- package/dist/src/core/mach-known-noise-filter.d.ts +41 -38
- package/dist/src/core/mach-known-noise-filter.js +53 -50
- package/dist/src/core/mach-mozconfig.d.ts +6 -6
- package/dist/src/core/mach-mozconfig.js +15 -15
- package/dist/src/core/mach-python.d.ts +2 -1
- package/dist/src/core/mach-python.js +4 -3
- package/dist/src/core/mach-resource-shim.d.ts +12 -12
- package/dist/src/core/mach-resource-shim.js +20 -20
- package/dist/src/core/mach.d.ts +23 -23
- package/dist/src/core/mach.js +36 -36
- package/dist/src/core/marionette-port.d.ts +15 -13
- package/dist/src/core/marionette-port.js +34 -31
- package/dist/src/core/marionette-preflight.d.ts +6 -6
- package/dist/src/core/marionette-preflight.js +23 -23
- package/dist/src/core/markdown-table.d.ts +9 -9
- package/dist/src/core/markdown-table.js +14 -14
- package/dist/src/core/mochitest-server-port.d.ts +8 -8
- package/dist/src/core/mochitest-server-port.js +14 -14
- package/dist/src/core/module-resolution-preflight.d.ts +8 -8
- package/dist/src/core/module-resolution-preflight.js +11 -11
- package/dist/src/core/moz-manifest-helpers.d.ts +7 -7
- package/dist/src/core/moz-manifest-helpers.js +7 -7
- package/dist/src/core/moz-manifest-register.d.ts +1 -1
- package/dist/src/core/moz-manifest-register.js +2 -2
- package/dist/src/core/moz-manifest-rules.js +11 -11
- package/dist/src/core/moz-manifest-tokenizers.js +1 -1
- package/dist/src/core/ownership-table.d.ts +5 -5
- package/dist/src/core/ownership-table.js +7 -7
- package/dist/src/core/parser-fallback.d.ts +3 -3
- package/dist/src/core/parser-fallback.js +3 -3
- package/dist/src/core/patch-apply-fuzz.d.ts +5 -5
- package/dist/src/core/patch-apply-fuzz.js +9 -9
- package/dist/src/core/patch-apply.d.ts +9 -9
- package/dist/src/core/patch-apply.js +30 -30
- package/dist/src/core/patch-export-update.d.ts +4 -4
- package/dist/src/core/patch-export-update.js +3 -3
- package/dist/src/core/patch-export.d.ts +10 -10
- package/dist/src/core/patch-export.js +13 -13
- package/dist/src/core/patch-identifier-suggest.d.ts +1 -1
- package/dist/src/core/patch-identifier-suggest.js +4 -4
- package/dist/src/core/patch-lint-binary.d.ts +7 -7
- package/dist/src/core/patch-lint-cache.d.ts +2 -2
- package/dist/src/core/patch-lint-cache.js +13 -13
- package/dist/src/core/patch-lint-checkjs.d.ts +26 -26
- package/dist/src/core/patch-lint-checkjs.js +42 -41
- package/dist/src/core/patch-lint-chrome-jsdoc.d.ts +8 -9
- package/dist/src/core/patch-lint-chrome-jsdoc.js +10 -11
- package/dist/src/core/patch-lint-creators.d.ts +3 -3
- package/dist/src/core/patch-lint-creators.js +3 -3
- package/dist/src/core/patch-lint-cross.d.ts +13 -13
- package/dist/src/core/patch-lint-cross.js +21 -21
- package/dist/src/core/patch-lint-css.d.ts +1 -1
- package/dist/src/core/patch-lint-css.js +5 -5
- package/dist/src/core/patch-lint-diff-tag.d.ts +5 -5
- package/dist/src/core/patch-lint-diff-tag.js +5 -5
- package/dist/src/core/patch-lint-diff.d.ts +4 -4
- package/dist/src/core/patch-lint-diff.js +4 -4
- package/dist/src/core/patch-lint-file-size.d.ts +3 -3
- package/dist/src/core/patch-lint-file-size.js +3 -3
- package/dist/src/core/patch-lint-forward-registration.d.ts +4 -4
- package/dist/src/core/patch-lint-forward-registration.js +12 -12
- package/dist/src/core/patch-lint-jsdoc.d.ts +2 -2
- package/dist/src/core/patch-lint-jsdoc.js +11 -11
- package/dist/src/core/patch-lint-module-registration.d.ts +1 -1
- package/dist/src/core/patch-lint-module-registration.js +1 -1
- package/dist/src/core/patch-lint-mozbuild.d.ts +1 -1
- package/dist/src/core/patch-lint-mozbuild.js +10 -10
- package/dist/src/core/patch-lint-observer.d.ts +3 -3
- package/dist/src/core/patch-lint-observer.js +7 -7
- package/dist/src/core/patch-lint-ownership.d.ts +6 -6
- package/dist/src/core/patch-lint-ownership.js +6 -6
- package/dist/src/core/patch-lint-prettier.d.ts +6 -6
- package/dist/src/core/patch-lint-prettier.js +6 -6
- package/dist/src/core/patch-lint-queue-types.d.ts +1 -1
- package/dist/src/core/patch-lint-queue-types.js +1 -1
- package/dist/src/core/patch-lint-staged-registration.d.ts +2 -2
- package/dist/src/core/patch-lint-staged-registration.js +6 -6
- package/dist/src/core/patch-lint-unmanaged-companion.d.ts +23 -23
- package/dist/src/core/patch-lint-unmanaged-companion.js +26 -26
- package/dist/src/core/patch-lint.d.ts +27 -26
- package/dist/src/core/patch-lint.js +48 -46
- package/dist/src/core/patch-lock.d.ts +1 -1
- package/dist/src/core/patch-lock.js +8 -8
- package/dist/src/core/patch-manifest-consistency.d.ts +7 -7
- package/dist/src/core/patch-manifest-consistency.js +16 -17
- package/dist/src/core/patch-manifest-files-affected.d.ts +1 -1
- package/dist/src/core/patch-manifest-files-affected.js +3 -3
- package/dist/src/core/patch-manifest-io.d.ts +14 -14
- package/dist/src/core/patch-manifest-io.js +27 -27
- package/dist/src/core/patch-manifest-query.d.ts +1 -1
- package/dist/src/core/patch-manifest-query.js +4 -4
- package/dist/src/core/patch-manifest-resolve.d.ts +5 -5
- package/dist/src/core/patch-manifest-resolve.js +7 -7
- package/dist/src/core/patch-manifest-validate.js +3 -3
- package/dist/src/core/patch-manifest.d.ts +2 -2
- package/dist/src/core/patch-manifest.js +2 -2
- package/dist/src/core/patch-parse.d.ts +14 -14
- package/dist/src/core/patch-parse.js +16 -16
- package/dist/src/core/patch-registration-refs.d.ts +4 -4
- package/dist/src/core/patch-registration-refs.js +7 -7
- package/dist/src/core/patch-transform.d.ts +8 -8
- package/dist/src/core/patch-transform.js +13 -13
- package/dist/src/core/process-cpu-time.d.ts +1 -1
- package/dist/src/core/process-cpu-time.js +5 -5
- package/dist/src/core/rebase-session.d.ts +7 -7
- package/dist/src/core/rebase-session.js +8 -8
- package/dist/src/core/register-result.d.ts +1 -1
- package/dist/src/core/register-result.js +1 -1
- package/dist/src/core/register-scaffold.d.ts +2 -2
- package/dist/src/core/register-scaffold.js +3 -3
- package/dist/src/core/register-shared-css.d.ts +3 -3
- package/dist/src/core/register-shared-css.js +4 -4
- package/dist/src/core/register-xpcshell-test.d.ts +2 -2
- package/dist/src/core/register-xpcshell-test.js +2 -2
- package/dist/src/core/run-log-redact.d.ts +12 -12
- package/dist/src/core/run-log-redact.js +16 -16
- package/dist/src/core/run-log.d.ts +9 -9
- package/dist/src/core/run-log.js +14 -14
- package/dist/src/core/shared-ftl.d.ts +2 -2
- package/dist/src/core/shared-ftl.js +6 -6
- package/dist/src/core/signal-critical.d.ts +2 -2
- package/dist/src/core/signal-critical.js +2 -2
- package/dist/src/core/smoke-patterns.d.ts +5 -5
- package/dist/src/core/smoke-patterns.js +9 -9
- package/dist/src/core/state-file.d.ts +3 -3
- package/dist/src/core/status-binary.d.ts +8 -8
- package/dist/src/core/status-binary.js +12 -12
- package/dist/src/core/status-classify.d.ts +17 -17
- package/dist/src/core/status-classify.js +11 -11
- package/dist/src/core/test-changed-prefs.d.ts +12 -12
- package/dist/src/core/test-changed-prefs.js +15 -15
- package/dist/src/core/test-harness-crash.d.ts +39 -39
- package/dist/src/core/test-harness-crash.js +67 -67
- package/dist/src/core/test-harness-output.d.ts +7 -7
- package/dist/src/core/test-harness-output.js +7 -7
- package/dist/src/core/test-harness-verdict-notes.d.ts +13 -14
- package/dist/src/core/test-harness-verdict-notes.js +4 -4
- package/dist/src/core/test-path-scope.d.ts +8 -8
- package/dist/src/core/test-path-scope.js +11 -11
- package/dist/src/core/test-stale-check.d.ts +22 -21
- package/dist/src/core/test-stale-check.js +29 -28
- package/dist/src/core/test-stale-symlink.d.ts +1 -1
- package/dist/src/core/test-stale-symlink.js +1 -1
- package/dist/src/core/test-stall-triage.d.ts +9 -9
- package/dist/src/core/test-stall-triage.js +22 -22
- package/dist/src/core/token-category.d.ts +4 -4
- package/dist/src/core/token-category.js +13 -12
- package/dist/src/core/token-coverage.js +4 -5
- package/dist/src/core/token-dark-mode.d.ts +17 -9
- package/dist/src/core/token-dark-mode.js +41 -28
- package/dist/src/core/token-docs.d.ts +1 -1
- package/dist/src/core/token-inventory.d.ts +6 -6
- package/dist/src/core/token-inventory.js +7 -7
- package/dist/src/core/token-manager.d.ts +3 -3
- package/dist/src/core/token-manager.js +21 -21
- package/dist/src/core/token-scaffold.d.ts +4 -4
- package/dist/src/core/token-scaffold.js +4 -4
- package/dist/src/core/token-variant.d.ts +14 -14
- package/dist/src/core/token-variant.js +32 -32
- package/dist/src/core/toolchain-preflight.d.ts +15 -15
- package/dist/src/core/toolchain-preflight.js +22 -22
- package/dist/src/core/tree-cow.d.ts +3 -3
- package/dist/src/core/tree-cow.js +6 -6
- package/dist/src/core/tree-guard.d.ts +3 -3
- package/dist/src/core/tree-guard.js +23 -23
- package/dist/src/core/tree-store.d.ts +15 -15
- package/dist/src/core/tree-store.js +35 -33
- package/dist/src/core/typecheck-shim.d.ts +16 -15
- package/dist/src/core/typecheck-shim.js +26 -25
- package/dist/src/core/typecheck.d.ts +12 -12
- package/dist/src/core/typecheck.js +31 -31
- package/dist/src/core/wire-destroy.d.ts +2 -2
- package/dist/src/core/wire-destroy.js +5 -5
- package/dist/src/core/wire-dom-fragment.d.ts +3 -3
- package/dist/src/core/wire-dom-fragment.js +6 -6
- package/dist/src/core/wire-init.d.ts +2 -2
- package/dist/src/core/wire-init.js +7 -7
- package/dist/src/core/wire-subscript.d.ts +1 -1
- package/dist/src/core/wire-subscript.js +3 -3
- package/dist/src/core/wire-utils.d.ts +9 -9
- package/dist/src/core/wire-utils.js +11 -11
- package/dist/src/core/xpcshell-appdir.d.ts +20 -20
- package/dist/src/core/xpcshell-appdir.js +26 -26
- package/dist/src/core/xpcshell-profile-dir.d.ts +3 -3
- package/dist/src/core/xpcshell-profile-dir.js +7 -7
- package/dist/src/errors/base.d.ts +22 -21
- package/dist/src/errors/base.js +22 -21
- package/dist/src/errors/build.d.ts +6 -6
- package/dist/src/errors/build.js +6 -6
- package/dist/src/errors/codes.d.ts +10 -10
- package/dist/src/errors/codes.js +10 -10
- package/dist/src/errors/furnace.d.ts +2 -2
- package/dist/src/errors/git.d.ts +1 -1
- package/dist/src/errors/git.js +1 -1
- package/dist/src/errors/patch.d.ts +3 -3
- package/dist/src/errors/patch.js +3 -3
- package/dist/src/errors/rebase.d.ts +1 -1
- package/dist/src/errors/rebase.js +1 -1
- package/dist/src/errors/run.d.ts +1 -1
- package/dist/src/errors/run.js +1 -1
- package/dist/src/index.d.ts +4 -4
- package/dist/src/index.js +4 -4
- package/dist/src/types/commands/options.d.ts +86 -85
- package/dist/src/types/commands/patches.d.ts +19 -19
- package/dist/src/types/commands/project.d.ts +3 -3
- package/dist/src/types/config.d.ts +24 -23
- package/dist/src/types/furnace.d.ts +17 -17
- package/dist/src/types/json.d.ts +3 -3
- package/dist/src/types/json.js +2 -2
- package/dist/src/types/typecheck.d.ts +3 -3
- package/dist/src/utils/assert.d.ts +1 -1
- package/dist/src/utils/assert.js +6 -6
- package/dist/src/utils/build-info.d.ts +5 -5
- package/dist/src/utils/build-info.js +6 -6
- package/dist/src/utils/child-env.d.ts +5 -5
- package/dist/src/utils/child-env.js +5 -5
- package/dist/src/utils/concurrency.d.ts +2 -2
- package/dist/src/utils/concurrency.js +2 -2
- package/dist/src/utils/elapsed.js +1 -1
- package/dist/src/utils/errors.d.ts +8 -8
- package/dist/src/utils/errors.js +8 -8
- package/dist/src/utils/fs.d.ts +1 -1
- package/dist/src/utils/fs.js +8 -8
- package/dist/src/utils/line-dispatch.d.ts +3 -3
- package/dist/src/utils/line-dispatch.js +5 -5
- package/dist/src/utils/logger.d.ts +4 -4
- package/dist/src/utils/logger.js +11 -11
- package/dist/src/utils/machine-output.js +2 -2
- package/dist/src/utils/options.d.ts +13 -13
- package/dist/src/utils/options.js +20 -20
- package/dist/src/utils/package-root.js +2 -2
- package/dist/src/utils/paths.d.ts +4 -4
- package/dist/src/utils/paths.js +4 -4
- package/dist/src/utils/process-group.d.ts +8 -8
- package/dist/src/utils/process-group.js +19 -19
- package/dist/src/utils/process.d.ts +34 -33
- package/dist/src/utils/process.js +20 -19
- package/dist/src/utils/ps-duration.d.ts +4 -4
- package/dist/src/utils/ps-duration.js +6 -6
- package/dist/src/utils/regex.d.ts +4 -4
- package/dist/src/utils/regex.js +7 -7
- package/dist/src/utils/sleep.d.ts +7 -7
- package/dist/src/utils/sleep.js +7 -7
- package/dist/src/utils/stdio-drain.d.ts +7 -7
- package/dist/src/utils/stdio-drain.js +8 -8
- package/dist/src/utils/validation.d.ts +11 -12
- package/dist/src/utils/validation.js +20 -21
- package/docs/README.md +2 -2
- package/docs/configuration.md +120 -114
- package/docs/exit-codes.md +63 -58
- package/docs/furnace.md +20 -19
- package/docs/lifecycle-invariants.md +412 -251
- package/docs/machine-output.md +33 -32
- package/docs/patch-workflow.md +48 -45
- package/docs/run-logs.md +62 -58
- package/docs/testing.md +101 -101
- package/docs/verification-trees.md +23 -22
- package/package.json +2 -2
|
@@ -9,16 +9,16 @@
|
|
|
9
9
|
* - startup crashes from the mozlog resource monitor on macOS
|
|
10
10
|
* (`AttributeError: 'SystemResourceMonitor' object has no attribute
|
|
11
11
|
* 'poll_interval'`, `host_statistics64(HOST_VM_INFO64) syscall failed`,
|
|
12
|
-
* `(ipc/mig) array not large enough
|
|
13
|
-
* abort the run before any test executes
|
|
12
|
+
* `(ipc/mig) array not large enough`, a psutil/macOS mismatch) which
|
|
13
|
+
* abort the run before any test executes.
|
|
14
14
|
* - hangs after browser startup that die at the no-output timeout yet still
|
|
15
|
-
* emit a `Passed: 0` summary
|
|
15
|
+
* emit a `Passed: 0` summary.
|
|
16
16
|
* - post-green shutdown re-entry, where a fully green run stalls on "must
|
|
17
17
|
* wait for focus" and records "Application shut down (without crashing)
|
|
18
18
|
* in the middle of a test!" as the only unexpected failure.
|
|
19
19
|
*
|
|
20
|
-
* Classification therefore keys on `TEST-START` presence
|
|
21
|
-
* never count as proof that tests ran
|
|
20
|
+
* Classification therefore keys on `TEST-START` presence, so summary lines
|
|
21
|
+
* never count as proof that tests ran, and recognizes the crash shapes
|
|
22
22
|
* above so the command layer can retry them with a bounded budget instead of
|
|
23
23
|
* reporting phantom test failures (or phantom passes).
|
|
24
24
|
*/
|
|
@@ -40,7 +40,7 @@ const GREEN_UNEXPECTED_SUMMARY_PATTERN = /\bUnexpected results:\s*0\b/;
|
|
|
40
40
|
const NONZERO_UNEXPECTED_SUMMARY_PATTERN = /\bUnexpected results:\s*[1-9]/;
|
|
41
41
|
/**
|
|
42
42
|
* Execution signals emitted by the suite-specific xpcshell dispatch
|
|
43
|
-
* (`mach xpcshell-test`), which does
|
|
43
|
+
* (`mach xpcshell-test`), which does not print `TEST-START` lines the way
|
|
44
44
|
* the generic `mach test` / browser-chrome dispatch does. A passing
|
|
45
45
|
* single-file xpcshell run prints a result-summary block instead
|
|
46
46
|
* (`TEST_END: Test PASS`, `Ran 16 checks`, `Unexpected results: 0`), so
|
|
@@ -49,16 +49,16 @@ const NONZERO_UNEXPECTED_SUMMARY_PATTERN = /\bUnexpected results:\s*[1-9]/;
|
|
|
49
49
|
*
|
|
50
50
|
* These markers are xpcshell-specific on purpose: the bare `Passed: 0` /
|
|
51
51
|
* `Failed: 0` summary that the no-output hang shape prints is deliberately
|
|
52
|
-
*
|
|
52
|
+
* not matched here, because that case must still read as `no-tests`.
|
|
53
53
|
*/
|
|
54
54
|
const XPCSHELL_RESULT_SUMMARY_PATTERN = /\bTEST_END\b|\bRan \d+ checks?\b|\bResult summary:/i;
|
|
55
55
|
const UNEXPECTED_LINE_PATTERN = /^.*\bTEST-UNEXPECTED-[A-Z-]+\b.*$/gm;
|
|
56
56
|
/**
|
|
57
|
-
* A `FAIL` token that is
|
|
57
|
+
* A `FAIL` token that is harness-shaped. Not a bare `\bFAIL\b`
|
|
58
58
|
* word match: that matched any output line containing the ordinary English
|
|
59
59
|
* word, so a test's own passing diagnostic could manufacture a red run (see
|
|
60
|
-
* {@link realUnexpectedFailureLines}). It also matched `TEST-KNOWN-FAIL
|
|
61
|
-
* an
|
|
60
|
+
* {@link realUnexpectedFailureLines}). It also matched `TEST-KNOWN-FAIL`,
|
|
61
|
+
* an expected failure, and counted it as a real one.
|
|
62
62
|
*
|
|
63
63
|
* The `TEST-` prefix is what makes the token the harness's rather than
|
|
64
64
|
* prose, and the negative lookahead is what keeps a known-fail annotation
|
|
@@ -67,11 +67,11 @@ const UNEXPECTED_LINE_PATTERN = /^.*\bTEST-UNEXPECTED-[A-Z-]+\b.*$/gm;
|
|
|
67
67
|
const FAIL_LINE_PATTERN = /^.*\bTEST-(?!KNOWN-FAIL\b)[A-Z-]*FAIL\b.*$/gm;
|
|
68
68
|
/**
|
|
69
69
|
* The three concrete shapes Gecko prints for a real assertion failure.
|
|
70
|
-
* Case-
|
|
70
|
+
* Case-sensitive and punctuation-anchored on purpose: the previous
|
|
71
71
|
* `/\b(?:Assertion failure|MOZ_ASSERT|ASSERTION)\b/gim` was
|
|
72
72
|
* case-insensitive, so the ordinary English word "assertion" in a passing
|
|
73
73
|
* diagnostic ("If an assertion below times out, this is why") was read as
|
|
74
|
-
* a failure
|
|
74
|
+
* a failure, and the verdict then named that diagnostic as the first real
|
|
75
75
|
* test failure, pointing the reader at the wrong line.
|
|
76
76
|
*/
|
|
77
77
|
const ASSERTION_LINE_PATTERN = /^.*(?:Assertion failure:|MOZ_ASSERT\(|###!!! ASSERTION).*$/gm;
|
|
@@ -81,7 +81,7 @@ const TRACEBACK_PATTERN = /Traceback \(most recent call last\)/;
|
|
|
81
81
|
const NO_OUTPUT_TIMEOUT_PATTERN = /timed out after \d+ seconds with no output/i;
|
|
82
82
|
/**
|
|
83
83
|
* Crash-marker lines mozcrash / the mochitest harness print when the browser
|
|
84
|
-
* process itself died. Matched against the
|
|
84
|
+
* process itself died. Matched against the raw output (never noise-stripped):
|
|
85
85
|
* any of these proves the run was truncated by a crash, so an embedded green
|
|
86
86
|
* summary is under-reporting, not a result. `Main app process: killed by
|
|
87
87
|
* SIGSEGV` at the second of eight files with a `Passed: 2 / Failed: 0`
|
|
@@ -103,10 +103,10 @@ const CRASH_MARKER_PATTERNS = [
|
|
|
103
103
|
*/
|
|
104
104
|
// A `_DegradedReading` fallback that is not a real namedtuple duck type
|
|
105
105
|
// crashes mozsystemmonitor on the fallback itself (`_build_meta` subscripts
|
|
106
|
-
// the reading
|
|
106
|
+
// the reading, `_collect` unpacks it). A startup abort with zero TEST-START
|
|
107
107
|
// lines from this family is a crash, not a test failure. The `_collect
|
|
108
|
-
// failed` variant is caught-and-logged, so it carries no Traceback header
|
|
109
|
-
//
|
|
108
|
+
// failed` variant is caught-and-logged, so it carries no Traceback header.
|
|
109
|
+
// It gets its own zero-TEST-START check in `detectHarnessCrashSignature`
|
|
110
110
|
// besides joining the traceback cluster.
|
|
111
111
|
const DEGRADED_READING_CRASH_SIGNALS = [
|
|
112
112
|
/'_DegradedReading' object is not subscriptable/,
|
|
@@ -123,7 +123,7 @@ const STARTUP_TRACEBACK_SIGNALS = [
|
|
|
123
123
|
// On a degraded host every collector sample is rejected, aggregation has
|
|
124
124
|
// nothing, and mozbuild's log_resource_usage dies on
|
|
125
125
|
// usage["io"].read_bytes AFTER a fully successful compile ("Error running
|
|
126
|
-
// mach" with complete artifacts). Environmental, not a build regression
|
|
126
|
+
// mach" with complete artifacts). Environmental, not a build regression:
|
|
127
127
|
// the protected build retries it, since an incremental retry is cheap and
|
|
128
128
|
// the guard keeps the retry green.
|
|
129
129
|
/AttributeError: 'NoneType' object has no attribute 'read_bytes'/,
|
|
@@ -165,8 +165,8 @@ const BENIGN_TRACEBACK_CONTEXT = /telemetry|glean/i;
|
|
|
165
165
|
* Strips non-signal noise from captured output before crash-signature
|
|
166
166
|
* matching: resource-monitor degradation warnings, and traceback blocks
|
|
167
167
|
* that mach caught itself (telemetry submission tracebacks are printed but
|
|
168
|
-
* never abort the run). The stripped text is used
|
|
169
|
-
*
|
|
168
|
+
* never abort the run). The stripped text is used only as crash evidence.
|
|
169
|
+
* Classification of test results still reads the full output.
|
|
170
170
|
*/
|
|
171
171
|
export function stripNonSignalNoise(output) {
|
|
172
172
|
const lines = output.split(/\r?\n/);
|
|
@@ -219,9 +219,9 @@ export function findCrashMarkerLine(output) {
|
|
|
219
219
|
/**
|
|
220
220
|
* True when the summary lines LOOK green: execution signal, `Unexpected
|
|
221
221
|
* results: 0` with no non-zero count, `SUITE_END`, no real
|
|
222
|
-
* `TEST-UNEXPECTED-*` lines.
|
|
223
|
-
* evidence
|
|
224
|
-
* {@link classifyHarnessRun} needs the distinction to report
|
|
222
|
+
* `TEST-UNEXPECTED-*` lines. Blind to crash/truncation
|
|
223
|
+
* evidence: {@link hasCompletedGreenSummary} layers that on top, and
|
|
224
|
+
* {@link classifyHarnessRun} needs the distinction to report why a
|
|
225
225
|
* green-shaped summary was rejected.
|
|
226
226
|
*/
|
|
227
227
|
function hasGreenShapedSummary(output) {
|
|
@@ -232,15 +232,15 @@ function hasGreenShapedSummary(output) {
|
|
|
232
232
|
realUnexpectedFailureLines(output).length === 0);
|
|
233
233
|
}
|
|
234
234
|
/**
|
|
235
|
-
* True when the output embeds a
|
|
235
|
+
* True when the output embeds a completed, green suite summary: an execution
|
|
236
236
|
* signal, `Unexpected results: 0` (and no non-zero unexpected count), a
|
|
237
|
-
* `SUITE_END` marker, no real `TEST-UNEXPECTED-*` lines
|
|
237
|
+
* `SUITE_END` marker, no real `TEST-UNEXPECTED-*` lines, and no crash
|
|
238
238
|
* marker. Such a run finished its suite, so any startup-traceback-shaped
|
|
239
|
-
* noise in the same output is
|
|
240
|
-
* signature-based crash classification
|
|
239
|
+
* noise in the same output is non-fatal and this vetoes
|
|
240
|
+
* signature-based crash classification. Without the veto, fully green
|
|
241
241
|
* sharded runs report `CRASH (N attempts)` because degradation warnings
|
|
242
|
-
* match the psutil signals. A summary printed after a crash marker is
|
|
243
|
-
* "completed"
|
|
242
|
+
* match the psutil signals. A summary printed after a crash marker is not
|
|
243
|
+
* "completed": it only covers the files that ran before the crash.
|
|
244
244
|
* Exported for direct unit testing.
|
|
245
245
|
*/
|
|
246
246
|
export function hasCompletedGreenSummary(output) {
|
|
@@ -252,7 +252,7 @@ const TEST_FILE_BASENAME_PATTERN = /^(?:browser|test)_.*\.m?js$/;
|
|
|
252
252
|
* Start/end execution markers, both log dialects: the structured mozlog
|
|
253
253
|
* `TEST_START`/`TEST_END` pair and the human browser-chrome
|
|
254
254
|
* `TEST-START`/`TEST-OK` pair. `TEST-UNEXPECTED-*` end shapes are
|
|
255
|
-
* irrelevant here
|
|
255
|
+
* irrelevant here, since any such line already fails the green-summary check
|
|
256
256
|
* before completeness is consulted.
|
|
257
257
|
*/
|
|
258
258
|
const START_MARKER_PATTERN = /\bTEST[-_]START\b[:| ]*\s*(\S+)?/;
|
|
@@ -262,11 +262,11 @@ const END_MARKER_PATTERN = /\bTEST[-_]END\b|\bTEST-OK\b/;
|
|
|
262
262
|
* requested file must produce a start marker, and every started test must
|
|
263
263
|
* produce an end marker (the harness emits both even for failing files).
|
|
264
264
|
*
|
|
265
|
-
* Ends are paired with starts
|
|
266
|
-
* the next end), not by filename
|
|
265
|
+
* Ends are paired with starts positionally (last open start is closed by
|
|
266
|
+
* the next end), not by filename: the xpcshell dialect's `TEST_END: Test
|
|
267
267
|
* PASS` lines do not name the file. Requested paths that are not
|
|
268
268
|
* test-file-shaped (directories, manifests) are skipped for the
|
|
269
|
-
* never-started check
|
|
269
|
+
* never-started check. The start/end pairing scan covers them regardless.
|
|
270
270
|
* Exported for direct unit testing.
|
|
271
271
|
*/
|
|
272
272
|
export function analyzeTestCompleteness(output, requestedPaths) {
|
|
@@ -302,7 +302,7 @@ export function analyzeTestCompleteness(output, requestedPaths) {
|
|
|
302
302
|
function hasXpcshellResultSummary(output) {
|
|
303
303
|
return XPCSHELL_RESULT_SUMMARY_PATTERN.test(output);
|
|
304
304
|
}
|
|
305
|
-
/** Unexpected-failure lines that are
|
|
305
|
+
/** Unexpected-failure lines that are not the shutdown re-entry artifact. */
|
|
306
306
|
function realUnexpectedFailureLines(output) {
|
|
307
307
|
const matches = [
|
|
308
308
|
...(output.match(UNEXPECTED_LINE_PATTERN) ?? []),
|
|
@@ -319,8 +319,8 @@ function realUnexpectedFailureLines(output) {
|
|
|
319
319
|
return [...new Set(matches.map((line) => line.trim()))].filter((line) => !SHUTDOWN_REENTRY_PATTERN.test(line));
|
|
320
320
|
}
|
|
321
321
|
/**
|
|
322
|
-
* Non-global copies of the unexpected/assertion patterns for per-line use
|
|
323
|
-
*
|
|
322
|
+
* Non-global copies of the unexpected/assertion patterns for per-line use.
|
|
323
|
+
* The `g`-flagged module patterns carry `lastIndex` state across `.test()`
|
|
324
324
|
* calls and must never be reused line-by-line.
|
|
325
325
|
*/
|
|
326
326
|
const UNEXPECTED_LINE_SINGLE = /\bTEST-UNEXPECTED-[A-Z-]+\b/;
|
|
@@ -338,7 +338,7 @@ const FAILURE_BLOCK_CONTEXT_LIMIT = 6;
|
|
|
338
338
|
* assertion/diff context, one string per block. The shutdown-reentry
|
|
339
339
|
* artifact is excluded (it is harness noise, not a test result). When more
|
|
340
340
|
* than `limit` blocks exist, a final `…(+N more …)` note is appended so the
|
|
341
|
-
* operator knows the echo was truncated. Pure
|
|
341
|
+
* operator knows the echo was truncated. Pure. Exported for unit tests.
|
|
342
342
|
*/
|
|
343
343
|
export function collectUnexpectedFailureBlocks(output, limit = 5) {
|
|
344
344
|
const lines = output.split(/\r?\n/);
|
|
@@ -404,7 +404,7 @@ export function detectHarnessCrashSignature(output) {
|
|
|
404
404
|
// A completed green embedded summary vetoes signature-based crash
|
|
405
405
|
// classification outright: the suite finished, so any startup-shaped
|
|
406
406
|
// noise in the same output was non-fatal. (The post-green shutdown
|
|
407
|
-
// re-entry shape below is exempt
|
|
407
|
+
// re-entry shape below is exempt: it is a crash verdict on
|
|
408
408
|
// an otherwise-green log, keyed on its own explicit markers.)
|
|
409
409
|
const greenSummaryVeto = hasCompletedGreenSummary(output);
|
|
410
410
|
// Startup traceback cluster (resource monitor / psutil), scanned over
|
|
@@ -443,7 +443,7 @@ export function detectHarnessCrashSignature(output) {
|
|
|
443
443
|
}
|
|
444
444
|
// Post-green shutdown re-entry: every unexpected line is the
|
|
445
445
|
// shutdown-mid-test artifact, the run stalled on focus, and at least one
|
|
446
|
-
// such artifact exists
|
|
446
|
+
// such artifact exists, on an otherwise green log.
|
|
447
447
|
const shutdownLine = findLine(output, [SHUTDOWN_REENTRY_PATTERN]);
|
|
448
448
|
if (shutdownLine && realFailures.length === 0 && FOCUS_STALL_PATTERN.test(output)) {
|
|
449
449
|
return { reason: 'post-green shutdown re-entry during harness teardown', line: shutdownLine };
|
|
@@ -454,20 +454,20 @@ export function detectHarnessCrashSignature(output) {
|
|
|
454
454
|
* Classifies a completed harness run. The decision tree, in order:
|
|
455
455
|
*
|
|
456
456
|
* 1. A recognized crash signature wins regardless of exit code (the
|
|
457
|
-
* shutdown re-entry shape exits non-zero on an otherwise green run
|
|
458
|
-
* the hang shape can even exit zero with a `Passed: 0` summary).
|
|
459
|
-
* 2. No execution signal with explicit paths requested means no test ran
|
|
457
|
+
* shutdown re-entry shape exits non-zero on an otherwise green run,
|
|
458
|
+
* and the hang shape can even exit zero with a `Passed: 0` summary).
|
|
459
|
+
* 2. No execution signal with explicit paths requested means no test ran:
|
|
460
460
|
* `no-tests`, even when the exit code is zero. The execution signal is
|
|
461
461
|
* a `TEST-START` line (generic `mach test` / browser-chrome dispatch)
|
|
462
|
-
*
|
|
462
|
+
* or the suite-specific xpcshell result-summary block (the xpcshell
|
|
463
463
|
* dispatch prints no `TEST-START`). Bare `Passed:`/`Failed:` summary
|
|
464
464
|
* lines are still not trusted as evidence of execution.
|
|
465
|
-
* 3. Exit code zero with tests started is a pass
|
|
466
|
-
* test failure for the regular diagnosis chain
|
|
467
|
-
* exit whose embedded summary completed green
|
|
465
|
+
* 3. Exit code zero with tests started is a pass. Anything else is a
|
|
466
|
+
* test failure for the regular diagnosis chain, except a non-zero
|
|
467
|
+
* exit whose embedded summary completed green and shows no crash
|
|
468
468
|
* marker and no truncated/never-started requested file, which is a
|
|
469
469
|
* pass with a `greenSummaryOverride` note (harness noise owns the
|
|
470
|
-
* exit code). A green-shaped summary
|
|
470
|
+
* exit code). A green-shaped summary with such evidence is rejected
|
|
471
471
|
* (`greenSummaryRejected`) and fails.
|
|
472
472
|
*/
|
|
473
473
|
export function classifyHarnessRun(exitCode, output, requestedPaths) {
|
|
@@ -476,10 +476,10 @@ export function classifyHarnessRun(exitCode, output, requestedPaths) {
|
|
|
476
476
|
const firstRealFailure = realFailures[0];
|
|
477
477
|
const failureBlocks = collectUnexpectedFailureBlocks(output);
|
|
478
478
|
const secondaryHarnessSignature = firstRealFailure !== undefined ? detectSecondaryHarnessNoise(output) : undefined;
|
|
479
|
-
// Checked
|
|
480
|
-
// in
|
|
479
|
+
// Checked before signature detection: a suite that ran clean and then died
|
|
480
|
+
// in known upstream teardown noise is a pass, not a crash. The teardown
|
|
481
481
|
// traceback matches the startup-traceback cluster, and the green-summary
|
|
482
|
-
// veto over that cluster requires a `SUITE_END` marker
|
|
482
|
+
// veto over that cluster requires a `SUITE_END` marker, which this very
|
|
483
483
|
// traceback is what prevents from printing. Without this check a
|
|
484
484
|
// substantively green suite (`Ran N checks` / `Unexpected results: 0`, no
|
|
485
485
|
// unexpected lines) reports CRASH, indistinguishable at the summary level
|
|
@@ -558,17 +558,17 @@ export function classifyHarnessRun(exitCode, output, requestedPaths) {
|
|
|
558
558
|
* unexplained residue is the recognized mozsystemmonitor teardown
|
|
559
559
|
* traceback.
|
|
560
560
|
*
|
|
561
|
-
* Requires, all of them: tests actually executed
|
|
562
|
-
* `Ran N checks` with an explicit `Unexpected results: 0
|
|
563
|
-
* unexpected count anywhere
|
|
564
|
-
* no crash marker
|
|
561
|
+
* Requires, all of them: tests actually executed, the summary printed
|
|
562
|
+
* `Ran N checks` with an explicit `Unexpected results: 0`, no non-zero
|
|
563
|
+
* unexpected count anywhere, no real `TEST-UNEXPECTED-*`/assertion line,
|
|
564
|
+
* no crash marker, every requested test file both started and ended, and
|
|
565
565
|
* the recognized teardown traceback is present. Anything short of that
|
|
566
|
-
* falls through to the normal (failing) chain
|
|
567
|
-
*
|
|
566
|
+
* falls through to the normal (failing) chain, with the failing condition
|
|
567
|
+
* named, so the next occurrence is a filed bug rather than another
|
|
568
568
|
* undiagnosable re-run.
|
|
569
569
|
*
|
|
570
|
-
* The conditions are evaluated in a fixed order and the
|
|
571
|
-
* is reported
|
|
570
|
+
* The conditions are evaluated in a fixed order and the first failing one
|
|
571
|
+
* is reported. A run can violate several, and reporting one deterministic
|
|
572
572
|
* condition beats an unordered list of everything that happened to be true.
|
|
573
573
|
*/
|
|
574
574
|
function evaluateGreenTeardownOverride(output, counts, realFailures, requestedPaths) {
|
|
@@ -601,7 +601,7 @@ function evaluateGreenTeardownOverride(output, counts, realFailures, requestedPa
|
|
|
601
601
|
if (crashLine !== undefined)
|
|
602
602
|
return reject(`crash marker present: ${truncateEvidence(crashLine)}`);
|
|
603
603
|
// The post-green shutdown re-entry shape is deliberately a crash verdict
|
|
604
|
-
// on an otherwise-green log
|
|
604
|
+
// on an otherwise-green log. It must not be swept up here.
|
|
605
605
|
if (SHUTDOWN_REENTRY_PATTERN.test(output)) {
|
|
606
606
|
return reject('post-green shutdown re-entry shape present');
|
|
607
607
|
}
|
|
@@ -616,8 +616,8 @@ function evaluateGreenTeardownOverride(output, counts, realFailures, requestedPa
|
|
|
616
616
|
}
|
|
617
617
|
/**
|
|
618
618
|
* Parses the numeric counts from the harness's embedded result summary
|
|
619
|
-
* (`Ran N checks` / `Unexpected results: N`). The
|
|
620
|
-
* wins
|
|
619
|
+
* (`Ran N checks` / `Unexpected results: N`). The last occurrence of each
|
|
620
|
+
* wins: a multi-suite run prints one summary per suite and the final one
|
|
621
621
|
* covers the aggregate the operator sees. Absent counts are omitted (the
|
|
622
622
|
* `FIREFORGE-VERDICT:` contract: an absent key means "summary did not
|
|
623
623
|
* print it", never zero).
|
|
@@ -642,9 +642,9 @@ function lastCapturedCount(output, pattern) {
|
|
|
642
642
|
return last;
|
|
643
643
|
}
|
|
644
644
|
/**
|
|
645
|
-
* Formats the machine-readable `FIREFORGE-VERDICT:` line
|
|
645
|
+
* Formats the machine-readable `FIREFORGE-VERDICT:` line: the stable,
|
|
646
646
|
* greppable last line every `fireforge test` run prints so harness-verdict
|
|
647
|
-
* consumers stop regexing mach internals. The status follows
|
|
647
|
+
* consumers stop regexing mach internals. The status follows this
|
|
648
648
|
* classifier, never the raw exit code: a crash-classified run says
|
|
649
649
|
* `FAIL reason=crash` even at exit 0, and a green-summary-override pass
|
|
650
650
|
* says `PASS` despite a non-zero mach exit. Count keys are omitted when
|
|
@@ -716,18 +716,18 @@ const SIGSEGV_EXIT_CODES = new Set([-11, 139]);
|
|
|
716
716
|
* `xpcshell return code: -11` with zero output is the signature of an
|
|
717
717
|
* `.sys.mjs` that a packaged module imports but whose `EXTRA_JS_MODULES`
|
|
718
718
|
* registration never landed: the module loader faults before any logging
|
|
719
|
-
* exists, so there is no import error, no stack, no test output
|
|
719
|
+
* exists, so there is no import error, no stack, no test output, just a
|
|
720
720
|
* dead process. It is indistinguishable from a genuine product crash
|
|
721
721
|
* unless someone names the cause.
|
|
722
722
|
*
|
|
723
|
-
* "Produced no evidence" is
|
|
723
|
+
* "Produced no evidence" is semantic rather than a byte
|
|
724
724
|
* budget: no execution signal, no real failure line, and no mozcrash
|
|
725
725
|
* marker. A run that got far enough to start a test, report a failure, or
|
|
726
726
|
* leave a crash dump has evidence of its own, and the regular diagnosis
|
|
727
|
-
* chain reads it
|
|
727
|
+
* chain reads it. This branch is only for the case where there is
|
|
728
728
|
* nothing else to say.
|
|
729
729
|
*
|
|
730
|
-
* Pure
|
|
730
|
+
* Pure. Exported for direct unit testing.
|
|
731
731
|
*
|
|
732
732
|
* @param exitCode - The harness process exit code
|
|
733
733
|
* @param output - Combined stdout/stderr from the run
|
|
@@ -767,7 +767,7 @@ export function buildSilentSegfaultMessage(exitCode, requestedPaths) {
|
|
|
767
767
|
}
|
|
768
768
|
/**
|
|
769
769
|
* Builds the message for a run that produced no `TEST-START` despite
|
|
770
|
-
* requesting paths
|
|
770
|
+
* requesting paths, including exit-code-zero runs whose `Passed: 0`
|
|
771
771
|
* summary would otherwise read as a silent false green.
|
|
772
772
|
*/
|
|
773
773
|
export function buildNoTestsRanMessage(exitCode, requestedPaths) {
|
|
@@ -11,20 +11,20 @@ export interface PostRebuildFailureContext {
|
|
|
11
11
|
/**
|
|
12
12
|
* Finds the first high-signal failure line from captured mach test output.
|
|
13
13
|
*
|
|
14
|
-
* Selection is
|
|
15
|
-
* `AttributeError:` arm above has exactly the same standing as
|
|
16
|
-
* `TEST-UNEXPECTED-FAIL
|
|
14
|
+
* Selection is by first matching line, not by first matching pattern, so the
|
|
15
|
+
* bare `AttributeError:` arm above has exactly the same standing as
|
|
16
|
+
* `TEST-UNEXPECTED-FAIL`: whichever appears earlier in the text wins. That
|
|
17
17
|
* is how a run whose real defect was an export shard's file-count assertion
|
|
18
|
-
* got diagnosed as the recognized mozsystemmonitor teardown crash
|
|
19
|
-
* information was present and the
|
|
18
|
+
* got diagnosed as the recognized mozsystemmonitor teardown crash. The
|
|
19
|
+
* information was present and the selection was wrong, which is the
|
|
20
20
|
* expensive kind of wrong, because the named cause is a real, documented,
|
|
21
21
|
* unrelated upstream defect and therefore reads as an answer.
|
|
22
22
|
*
|
|
23
23
|
* So a capture carrying the recognized teardown incident gets two passes:
|
|
24
24
|
* candidates excluding its `AttributeError` header first, and only if that
|
|
25
25
|
* finds nothing does the full set apply. The narrowness the rest of the
|
|
26
|
-
* codebase maintains is preserved exactly
|
|
27
|
-
* `hasKnownTeardownNoise` for the
|
|
26
|
+
* codebase maintains is preserved exactly: the exclusion is gated on
|
|
27
|
+
* `hasKnownTeardownNoise` for the whole capture, so it requires both the
|
|
28
28
|
* closed attribute allowlist and a `resourcemonitor.py` frame. A novel
|
|
29
29
|
* attribute, or a traceback from anywhere else, stays a real failure and is
|
|
30
30
|
* still eligible to be reported.
|
|
@@ -26,20 +26,20 @@ const FAILURE_LINE_PATTERNS = [
|
|
|
26
26
|
/**
|
|
27
27
|
* Finds the first high-signal failure line from captured mach test output.
|
|
28
28
|
*
|
|
29
|
-
* Selection is
|
|
30
|
-
* `AttributeError:` arm above has exactly the same standing as
|
|
31
|
-
* `TEST-UNEXPECTED-FAIL
|
|
29
|
+
* Selection is by first matching line, not by first matching pattern, so the
|
|
30
|
+
* bare `AttributeError:` arm above has exactly the same standing as
|
|
31
|
+
* `TEST-UNEXPECTED-FAIL`: whichever appears earlier in the text wins. That
|
|
32
32
|
* is how a run whose real defect was an export shard's file-count assertion
|
|
33
|
-
* got diagnosed as the recognized mozsystemmonitor teardown crash
|
|
34
|
-
* information was present and the
|
|
33
|
+
* got diagnosed as the recognized mozsystemmonitor teardown crash. The
|
|
34
|
+
* information was present and the selection was wrong, which is the
|
|
35
35
|
* expensive kind of wrong, because the named cause is a real, documented,
|
|
36
36
|
* unrelated upstream defect and therefore reads as an answer.
|
|
37
37
|
*
|
|
38
38
|
* So a capture carrying the recognized teardown incident gets two passes:
|
|
39
39
|
* candidates excluding its `AttributeError` header first, and only if that
|
|
40
40
|
* finds nothing does the full set apply. The narrowness the rest of the
|
|
41
|
-
* codebase maintains is preserved exactly
|
|
42
|
-
* `hasKnownTeardownNoise` for the
|
|
41
|
+
* codebase maintains is preserved exactly: the exclusion is gated on
|
|
42
|
+
* `hasKnownTeardownNoise` for the whole capture, so it requires both the
|
|
43
43
|
* closed attribute allowlist and a `resourcemonitor.py` frame. A novel
|
|
44
44
|
* attribute, or a traceback from anywhere else, stays a real failure and is
|
|
45
45
|
* still eligible to be reported.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Verdict-note helpers for the harness classifier.
|
|
3
3
|
*
|
|
4
4
|
* Split out of `test-harness-crash.ts` (at its per-file line budget). These
|
|
5
|
-
* decide the
|
|
5
|
+
* decide the advisory parenthetical on the `FIREFORGE-VERDICT:` line. None
|
|
6
6
|
* of them changes a status or a reason key, which the verdict contract's
|
|
7
7
|
* consumers parse.
|
|
8
8
|
*/
|
|
@@ -21,12 +21,12 @@ interface SummaryCountsView {
|
|
|
21
21
|
* `Unexpected results: 0`, yet the run is still classified `test-failures`
|
|
22
22
|
* on evidence lines that carry NO `TEST-UNEXPECTED-*` marker.
|
|
23
23
|
*
|
|
24
|
-
* `unexpected=0` printed beside `reason=test-failures`
|
|
25
|
-
*
|
|
24
|
+
* `unexpected=0` printed beside `reason=test-failures` means the verdict
|
|
25
|
+
* rests on pattern matching rather than on a harness result, and a
|
|
26
26
|
* reader who cannot see that spends hours attributing a red run to the
|
|
27
27
|
* change under test. The note says so on the verdict line itself.
|
|
28
28
|
*
|
|
29
|
-
*
|
|
29
|
+
* This is a note and not a reclassification: a non-zero exit with no
|
|
30
30
|
* green-shaped summary is still a failing run, and inventing a new `reason`
|
|
31
31
|
* would break the `FIREFORGE-VERDICT:` contract its consumers parse.
|
|
32
32
|
*/
|
|
@@ -36,16 +36,15 @@ export declare function truncateEvidence(line: string): string;
|
|
|
36
36
|
/**
|
|
37
37
|
* Outcome of the green-teardown belt.
|
|
38
38
|
*
|
|
39
|
-
* `accepted` is the pass. A rejection carries `rejectedBy`
|
|
40
|
-
* recognized teardown noise was present
|
|
41
|
-
* that could have applied and did not. That
|
|
42
|
-
*
|
|
43
|
-
*
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
48
|
-
* worth of effort guessing between them.
|
|
39
|
+
* `accepted` is the pass. A rejection carries `rejectedBy` only when the
|
|
40
|
+
* recognized teardown noise was present, i.e. when the belt was the thing
|
|
41
|
+
* that could have applied and did not. That is what the field is for: a run
|
|
42
|
+
* with no teardown traceback was never a candidate and naming a "rejecting
|
|
43
|
+
* condition" for it would be noise, whereas a run that does carry the
|
|
44
|
+
* traceback and still fails is the shape an operator otherwise cannot
|
|
45
|
+
* diagnose from outside. Every condition is all-or-nothing, so the failing
|
|
46
|
+
* verdict looks identical whichever one rejected it, and a downstream report
|
|
47
|
+
* spent a re-run and a filed-bug's worth of effort guessing between them.
|
|
49
48
|
*/
|
|
50
49
|
export interface GreenTeardownOverride {
|
|
51
50
|
accepted: boolean;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Verdict-note helpers for the harness classifier.
|
|
4
4
|
*
|
|
5
5
|
* Split out of `test-harness-crash.ts` (at its per-file line budget). These
|
|
6
|
-
* decide the
|
|
6
|
+
* decide the advisory parenthetical on the `FIREFORGE-VERDICT:` line. None
|
|
7
7
|
* of them changes a status or a reason key, which the verdict contract's
|
|
8
8
|
* consumers parse.
|
|
9
9
|
*/
|
|
@@ -19,12 +19,12 @@ const UNEXPECTED_MARKER = /TEST-UNEXPECTED-\w+/;
|
|
|
19
19
|
* `Unexpected results: 0`, yet the run is still classified `test-failures`
|
|
20
20
|
* on evidence lines that carry NO `TEST-UNEXPECTED-*` marker.
|
|
21
21
|
*
|
|
22
|
-
* `unexpected=0` printed beside `reason=test-failures`
|
|
23
|
-
*
|
|
22
|
+
* `unexpected=0` printed beside `reason=test-failures` means the verdict
|
|
23
|
+
* rests on pattern matching rather than on a harness result, and a
|
|
24
24
|
* reader who cannot see that spends hours attributing a red run to the
|
|
25
25
|
* change under test. The note says so on the verdict line itself.
|
|
26
26
|
*
|
|
27
|
-
*
|
|
27
|
+
* This is a note and not a reclassification: a non-zero exit with no
|
|
28
28
|
* green-shaped summary is still a failing run, and inventing a new `reason`
|
|
29
29
|
* would break the `FIREFORGE-VERDICT:` contract its consumers parse.
|
|
30
30
|
*/
|
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Directory-argument scope analysis for `fireforge test`.
|
|
3
3
|
*
|
|
4
|
-
* mozbuild's test resolver matches command-line paths by
|
|
4
|
+
* mozbuild's test resolver matches command-line paths by string prefix, so
|
|
5
5
|
* `fireforge test browser/base/content/test/hominis` also runs the sibling
|
|
6
|
-
* directory `browser/base/content/test/hominis-tiles
|
|
6
|
+
* directory `browser/base/content/test/hominis-tiles`, silently, and with
|
|
7
7
|
* no indication the scope widened.
|
|
8
8
|
*
|
|
9
|
-
* FireForge therefore treats a directory argument as meaning
|
|
9
|
+
* FireForge therefore treats a directory argument as meaning exactly that
|
|
10
10
|
* directory: {@link analyzeTestPathScopes} enumerates the test files of
|
|
11
|
-
* exactly that directory and dispatches
|
|
11
|
+
* exactly that directory and dispatches that explicit file list to mach,
|
|
12
12
|
* because a file list cannot prefix-match anything. Normalizing the
|
|
13
|
-
* directory with a trailing `/` does
|
|
13
|
+
* directory with a trailing `/` does not work. Mach still sweeps in the
|
|
14
14
|
* prefix-named sibling. The prefix-matching sibling directories are still
|
|
15
15
|
* reported so the command layer can tell the operator what was excluded.
|
|
16
16
|
*
|
|
17
17
|
* FireForge already rejects non-existent paths up front, so raw
|
|
18
|
-
* prefix-widening was never something an operator could invoke
|
|
19
|
-
*
|
|
18
|
+
* prefix-widening was never something an operator could invoke on purpose.
|
|
19
|
+
* It only ever happened by accident.
|
|
20
20
|
*/
|
|
21
21
|
/** A sibling directory the raw mach prefix match would have included. */
|
|
22
22
|
export interface SiblingPrefixMatch {
|
|
@@ -34,7 +34,7 @@ export interface TestPathScope {
|
|
|
34
34
|
* list for a directory (mach cannot prefix-widen an explicit file
|
|
35
35
|
* list), or the argument unchanged for files. A directory containing
|
|
36
36
|
* no enumerable test files falls back to the trailing-`/` directory
|
|
37
|
-
* form
|
|
37
|
+
* form: there is nothing to list, and mach owns the "no tests found"
|
|
38
38
|
* failure.
|
|
39
39
|
*/
|
|
40
40
|
dispatchPaths: string[];
|
|
@@ -2,22 +2,22 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* Directory-argument scope analysis for `fireforge test`.
|
|
4
4
|
*
|
|
5
|
-
* mozbuild's test resolver matches command-line paths by
|
|
5
|
+
* mozbuild's test resolver matches command-line paths by string prefix, so
|
|
6
6
|
* `fireforge test browser/base/content/test/hominis` also runs the sibling
|
|
7
|
-
* directory `browser/base/content/test/hominis-tiles
|
|
7
|
+
* directory `browser/base/content/test/hominis-tiles`, silently, and with
|
|
8
8
|
* no indication the scope widened.
|
|
9
9
|
*
|
|
10
|
-
* FireForge therefore treats a directory argument as meaning
|
|
10
|
+
* FireForge therefore treats a directory argument as meaning exactly that
|
|
11
11
|
* directory: {@link analyzeTestPathScopes} enumerates the test files of
|
|
12
|
-
* exactly that directory and dispatches
|
|
12
|
+
* exactly that directory and dispatches that explicit file list to mach,
|
|
13
13
|
* because a file list cannot prefix-match anything. Normalizing the
|
|
14
|
-
* directory with a trailing `/` does
|
|
14
|
+
* directory with a trailing `/` does not work. Mach still sweeps in the
|
|
15
15
|
* prefix-named sibling. The prefix-matching sibling directories are still
|
|
16
16
|
* reported so the command layer can tell the operator what was excluded.
|
|
17
17
|
*
|
|
18
18
|
* FireForge already rejects non-existent paths up front, so raw
|
|
19
|
-
* prefix-widening was never something an operator could invoke
|
|
20
|
-
*
|
|
19
|
+
* prefix-widening was never something an operator could invoke on purpose.
|
|
20
|
+
* It only ever happened by accident.
|
|
21
21
|
*/
|
|
22
22
|
import { readdir, stat } from 'node:fs/promises';
|
|
23
23
|
import { basename, dirname, join } from 'node:path';
|
|
@@ -26,7 +26,7 @@ const TEST_FILE_PATTERN = /^(?:browser|test)_.*\.(?:m?js|x?html)$/;
|
|
|
26
26
|
/**
|
|
27
27
|
* Recursively enumerates test-implementation files under a directory,
|
|
28
28
|
* returned engine-relative and sorted for deterministic dispatch order.
|
|
29
|
-
* Returns [] when the directory cannot be read
|
|
29
|
+
* Returns [] when the directory cannot be read. The caller then falls
|
|
30
30
|
* back to the directory form and mach owns the failure.
|
|
31
31
|
*/
|
|
32
32
|
async function collectTestFiles(dir, relPrefix) {
|
|
@@ -95,13 +95,13 @@ async function analyzeTestPathScope(engineDir, requestedPath) {
|
|
|
95
95
|
}
|
|
96
96
|
}
|
|
97
97
|
catch {
|
|
98
|
-
// Unreadable parent: skip the sibling probe
|
|
98
|
+
// Unreadable parent: skip the sibling probe. Exactness via the
|
|
99
99
|
// explicit file list is preserved regardless.
|
|
100
100
|
}
|
|
101
101
|
const testFiles = await collectTestFiles(absolute, `${stripped}/`);
|
|
102
102
|
return {
|
|
103
103
|
requestedPath,
|
|
104
|
-
// The explicit file list is what makes the selection exact
|
|
104
|
+
// The explicit file list is what makes the selection exact. An empty
|
|
105
105
|
// enumeration falls back to the directory form.
|
|
106
106
|
dispatchPaths: testFiles.length > 0 ? testFiles : [`${stripped}/`],
|
|
107
107
|
isDirectory: true,
|
|
@@ -135,7 +135,7 @@ export function formatScopeNotice(scope) {
|
|
|
135
135
|
.join(', ');
|
|
136
136
|
if (scope.testFileCount === 0) {
|
|
137
137
|
// Fallback dispatch: with nothing to enumerate, the raw directory form
|
|
138
|
-
// goes to mach, whose prefix matching
|
|
138
|
+
// goes to mach, whose prefix matching can sweep the siblings in.
|
|
139
139
|
// Claiming exclusion here would be a lie.
|
|
140
140
|
return (`${requestedDir}/ contains no enumerable test files, so the directory is passed to mach ` +
|
|
141
141
|
`as-is — mach resolves paths by string prefix, which may also select: ${siblings}.`);
|