Skip to content

Commit efa5eca

Browse files
committed
Adjust regex to be consistent with others per Tim
1 parent c59b7e4 commit efa5eca

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

scripts/dev/bless_tests.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,8 @@ function normalizeOutput(string $out): string {
7676
$out = preg_replace('/string\(\d+\) "([^"]*%d)/', 'string(%d) "$1', $out);
7777
// Inside of strings, replace absolute paths that have been truncated with
7878
// any string. These tend to contain homedirs with usernames, not good.
79-
$out = preg_replace("/'\\/.*\.\\.\\.'/", "'%s'", $out);
80-
$out = preg_replace("/'file:\/\\/.*\.\\.\\.'/", "'%s'", $out);
79+
$out = preg_replace("/'(\/|[A-Z]:\\\\)\S+\\.\\.\\.'/", "'%s'", $out);
80+
$out = preg_replace("/'file:(\/|[A-Z]:\\\\)\S+\\.\\.\\.'/", "'%s'", $out);
8181
$out = str_replace("\0", '%0', $out);
8282
return $out;
8383
}

0 commit comments

Comments
 (0)