| fetch-test-data.js |
|
95517 |
- |
| JSON_FORMAT.md |
|
34788 |
- |
| profile-worker.js |
)?[^\s'"`]*(?:xpc-profile-[a-z0-9_]{8}|tmp[a-z0-9_]{8}\.mozrunner)([^\s'"`]*)/g;
// Replace the path of a file of the profile of the instance under test with a
// "<profile>" relative path. Without this the same file is a different string in
// every job, and a different string on every platform. What follows the profile
// directory keeps forward slashes, so that a Windows path is the same string as
// the POSIX one.
function normalizeProfilePaths(string) {
return string.replace(
PROFILE_PATH_REGEXP,
(match, scheme = "", inProfile) =>
`${scheme}<profile>${inProfile.replace(/\\+/g, "/")}`
);
}
// The authority of a URL, followed by the port httpd.js or one of the other test
// servers was given at runtime. An IPv6 host keeps its brackets ("http://[::1]").
// "localhost" is also matched without a scheme, for the URLs devtools serializes
// into its error messages. Only these forms are matched because a position in a
// stack frame ("Front.js:335:14") would otherwise look like a host and a port.
const PORT_REGEXP =
/(:\/\/(?:\[[^\]\s]*\]|[^\s/:'"`\\]+)|(?<![\w./])localhost):\d{2,5}(?![\w.])/g;
// A path quoted in a message, eg. the file of a stack frame or the file a failed
// operation was on. Only the paths normalizeSourcePath can shorten are matched:
// those below a build or test worker directory, and those in the profile.
const QUOTED_PATH_REGEXP =
/[^\s'"`]*(?:checkouts[\\/]+gecko|build[\\/]+tests|obj-build|xpc-profile-[a-z0-9_]{8}|tmp[a-z0-9_]{8}\.mozrunner)[^\s'"`] |
25087 |
- |