Show More
@@ -1527,6 +1527,7 b' class TTest(Test):' | |||||
1527 | @staticmethod |
|
1527 | @staticmethod | |
1528 | def rematch(el, l): |
|
1528 | def rematch(el, l): | |
1529 | try: |
|
1529 | try: | |
|
1530 | el = b'(?:' + el + b')' | |||
1530 | # use \Z to ensure that the regex matches to the end of the string |
|
1531 | # use \Z to ensure that the regex matches to the end of the string | |
1531 | if os.name == 'nt': |
|
1532 | if os.name == 'nt': | |
1532 | return re.match(el + br'\r?\n\Z', l) |
|
1533 | return re.match(el + br'\r?\n\Z', l) |
@@ -98,19 +98,22 b' failing test' | |||||
98 |
|
98 | |||
99 | test churn with globs |
|
99 | test churn with globs | |
100 | $ cat > test-failure.t <<EOF |
|
100 | $ cat > test-failure.t <<EOF | |
101 | > $ echo "bar-baz"; echo "bar-bad" |
|
101 | > $ echo "bar-baz"; echo "bar-bad"; echo foo | |
102 | > bar*bad (glob) |
|
102 | > bar*bad (glob) | |
103 | > bar*baz (glob) |
|
103 | > bar*baz (glob) | |
|
104 | > | fo (re) | |||
104 | > EOF |
|
105 | > EOF | |
105 |
$ |
|
106 | $ rt test-failure.t | |
106 |
|
107 | |||
107 | --- $TESTTMP/test-failure.t |
|
108 | --- $TESTTMP/test-failure.t | |
108 | +++ $TESTTMP/test-failure.t.err |
|
109 | +++ $TESTTMP/test-failure.t.err | |
109 |
@@ -1, |
|
110 | @@ -1,4 +1,4 @@ | |
110 | $ echo "bar-baz"; echo "bar-bad" |
|
111 | $ echo "bar-baz"; echo "bar-bad"; echo foo | |
111 | + bar*baz (glob) |
|
112 | + bar*baz (glob) | |
112 | bar*bad (glob) |
|
113 | bar*bad (glob) | |
113 | - bar*baz (glob) |
|
114 | - bar*baz (glob) | |
|
115 | - | fo (re) | |||
|
116 | + foo | |||
114 |
|
117 | |||
115 | ERROR: test-failure.t output changed |
|
118 | ERROR: test-failure.t output changed | |
116 | ! |
|
119 | ! | |
@@ -126,11 +129,13 b' test diff colorisation' | |||||
126 |
|
129 | |||
127 | \x1b[38;5;124m--- $TESTTMP/test-failure.t\x1b[39m (esc) |
|
130 | \x1b[38;5;124m--- $TESTTMP/test-failure.t\x1b[39m (esc) | |
128 | \x1b[38;5;34m+++ $TESTTMP/test-failure.t.err\x1b[39m (esc) |
|
131 | \x1b[38;5;34m+++ $TESTTMP/test-failure.t.err\x1b[39m (esc) | |
129 |
\x1b[38;5;90;01m@@ -1, |
|
132 | \x1b[38;5;90;01m@@ -1,4 +1,4 @@\x1b[39;00m (esc) | |
130 | $ echo "bar-baz"; echo "bar-bad" |
|
133 | $ echo "bar-baz"; echo "bar-bad"; echo foo | |
131 | \x1b[38;5;34m+ bar*baz (glob)\x1b[39m (esc) |
|
134 | \x1b[38;5;34m+ bar*baz (glob)\x1b[39m (esc) | |
132 | bar*bad (glob) |
|
135 | bar*bad (glob) | |
133 | \x1b[38;5;124m- bar*baz (glob)\x1b[39m (esc) |
|
136 | \x1b[38;5;124m- bar*baz (glob)\x1b[39m (esc) | |
|
137 | \x1b[38;5;124m- | fo (re)\x1b[39m (esc) | |||
|
138 | \x1b[38;5;34m+ foo\x1b[39m (esc) | |||
134 |
|
139 | |||
135 | \x1b[38;5;88mERROR: \x1b[39m\x1b[38;5;9mtest-failure.t\x1b[39m\x1b[38;5;88m output changed\x1b[39m (esc) |
|
140 | \x1b[38;5;88mERROR: \x1b[39m\x1b[38;5;9mtest-failure.t\x1b[39m\x1b[38;5;88m output changed\x1b[39m (esc) | |
136 | ! |
|
141 | ! | |
@@ -145,11 +150,13 b' test diff colorisation' | |||||
145 |
|
150 | |||
146 | --- $TESTTMP/test-failure.t |
|
151 | --- $TESTTMP/test-failure.t | |
147 | +++ $TESTTMP/test-failure.t.err |
|
152 | +++ $TESTTMP/test-failure.t.err | |
148 |
@@ -1, |
|
153 | @@ -1,4 +1,4 @@ | |
149 | $ echo "bar-baz"; echo "bar-bad" |
|
154 | $ echo "bar-baz"; echo "bar-bad"; echo foo | |
150 | + bar*baz (glob) |
|
155 | + bar*baz (glob) | |
151 | bar*bad (glob) |
|
156 | bar*bad (glob) | |
152 | - bar*baz (glob) |
|
157 | - bar*baz (glob) | |
|
158 | - | fo (re) | |||
|
159 | + foo | |||
153 |
|
160 | |||
154 | ERROR: test-failure.t output changed |
|
161 | ERROR: test-failure.t output changed | |
155 | ! |
|
162 | ! |
General Comments 0
You need to be logged in to leave comments.
Login now