comparison tests/test-run-tests.t @ 33695:eeed23508383

run-tests: drop required (feature !) style lines when the output is missing Essentially, these were acting as a verbose (?) flag, since they weren't being dropped when required. Foozy has a nice description [1]. Basically, a couple more places needed to check the features before treating it as optional. I don't like how test-run-tests.py had to be hacked, but _hghave() can't be made a static method. The test change was a change while developing `debugssl`, prior to tightening up the cases where the message is printed, that this fix would have caught. [1] https://www.mercurial-scm.org/pipermail/mercurial-devel/2017-July/101941.html
author Matt Harbison <matt_harbison@yahoo.com>
date Tue, 18 Jul 2017 00:12:44 -0400
parents 754569f5e999
children 1fa6023240f4
comparison
equal deleted inserted replaced
33694:93422d0068f8 33695:eeed23508383
155 ! 155 !
156 Failed test-failure.t: output changed 156 Failed test-failure.t: output changed
157 # Ran 1 tests, 0 skipped, 1 failed. 157 # Ran 1 tests, 0 skipped, 1 failed.
158 python hash seed: * (glob) 158 python hash seed: * (glob)
159 #endif 159 #endif
160
161 $ cat > test-failure.t << EOF
162 > $ true
163 > should go away (true !)
164 > $ true
165 > should stay (false !)
166 >
167 > Should remove first line, not second or third
168 > $ echo 'testing'
169 > baz*foo (glob) (true !)
170 > foobar*foo (glob) (false !)
171 > te*ting (glob) (true !)
172 >
173 > Should keep first two lines, remove third and last
174 > $ echo 'testing'
175 > test.ng (re) (true !)
176 > foo.ar (re) (false !)
177 > b.r (re) (true !)
178 > missing (?)
179 > awol (true !)
180 > EOF
181 $ rt test-failure.t
182
183 --- $TESTTMP/test-failure.t
184 +++ $TESTTMP/test-failure.t.err
185 @@ -1,11 +1,9 @@
186 $ true
187 - should go away (true !)
188 $ true
189 should stay (false !)
190
191 Should remove first line, not second or third
192 $ echo 'testing'
193 - baz*foo (glob) (true !)
194 foobar*foo (glob) (false !)
195 te*ting (glob) (true !)
196
197 @@ -13,6 +11,4 @@
198 $ echo 'testing'
199 test.ng (re) (true !)
200 foo.ar (re) (false !)
201 - b.r (re) (true !)
202 missing (?)
203 - awol (true !)
204
205 ERROR: test-failure.t output changed
206 !
207 Failed test-failure.t: output changed
208 # Ran 1 tests, 0 skipped, 1 failed.
209 python hash seed: * (glob)
210 [1]
160 211
161 basic failing test 212 basic failing test
162 $ cat > test-failure.t << EOF 213 $ cat > test-failure.t << EOF
163 > $ echo babar 214 > $ echo babar
164 > rataxes 215 > rataxes