Skip to content

Commit ed89311

Browse files
BridgeARZYSzys
authored andcommitted
test: do not strip left whitespace in pseudo-tty tests
PR-URL: #27244 Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Beth Griggs <[email protected]> Reviewed-By: Jeremiah Senkpiel <[email protected]>
1 parent 8712edf commit ed89311

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

test/pseudo-tty/console_colors.out

+6-6
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ string q
33
{ foo: *[32m'bar'*[39m } with object format param
44

55
Error: test
6-
at abc (../fixtures/node_modules/bar.js:4:4)
6+
at abc (../fixtures/node_modules/bar.js:4:4)
77
foobar
8-
at * (*console_colors.js:*:*)
8+
at * (*console_colors.js:*:*)
99
*[90m at * (internal*:*:*)*[39m
1010
*[90m at *[39m
1111
*[90m at *[39m
@@ -14,22 +14,22 @@ at * (*console_colors.js:*:*)
1414
*[90m at *[39m
1515

1616
Error: Should not ever get here.
17-
at * (*node_modules*[4m*node_modules*[24m*bar.js:*:*)
17+
at * (*node_modules*[4m*node_modules*[24m*bar.js:*:*)
1818
*[90m at *[39m
1919
*[90m at *[39m
2020
*[90m at *[39m
2121
*[90m at *[39m
2222
*[90m at *[39m
2323
*[90m at *[39m
24-
at * (*console_colors.js:*:*)
24+
at * (*console_colors.js:*:*)
2525
*[90m at *[39m
2626
*[90m at *[39m
2727

2828
Error
29-
at evalmachine.<anonymous>:*:*
29+
at evalmachine.<anonymous>:*:*
3030
*[90m at Script.runInThisContext (vm.js:*:*)*[39m
3131
*[90m at Object.runInThisContext (vm.js:*:*)*[39m
32-
at * (*console_colors.js:*:*)
32+
at * (*console_colors.js:*:*)
3333
*[90m at *[39m
3434
*[90m at *[39m
3535
*[90m at *[39m

test/pseudo-tty/testcfg.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ def IsFailureOutput(self, output):
6666
patterns.append(pattern)
6767
# Compare actual output with the expected
6868
raw_lines = (output.stdout + output.stderr).split('\n')
69-
outlines = [ s.strip() for s in raw_lines if not self.IgnoreLine(s) ]
69+
outlines = [ s.rstrip() for s in raw_lines if not self.IgnoreLine(s) ]
7070
if len(outlines) != len(patterns):
7171
print("length differs.")
7272
print("expect=%d" % len(patterns))

0 commit comments

Comments
 (0)