Mercurial > public > mercurial-scm > hg-stable
diff tests/test-run-tests.t @ 42177:c1850798f995 stable
run-tests: stop matching line for missing feature
Before this change, the following unified test input would silently pass
$ echo foo
foo (false !)
After this change, the "foo" output is properly detected as unexpected.
The output of an handful of test had to be updated from broken conditional (that
ended up working by chance).
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Wed, 19 Jun 2019 05:37:33 +0200 |
parents | 0ae89ab3f025 |
children | bac24a8a095a |
line wrap: on
line diff
--- a/tests/test-run-tests.t Sun Jun 16 12:31:07 2019 +0900 +++ b/tests/test-run-tests.t Wed Jun 19 05:37:33 2019 +0200 @@ -1936,3 +1936,70 @@ running 1 tests using 1 parallel processes . # Ran 1 tests, 0 skipped, 0 failed. + +Test conditional output matching +================================ + + $ cat << EOF >> test-conditional-matching.t + > #testcases foo bar + > $ echo richtig + > richtig (true !) + > $ echo falsch + > falsch (false !) + > #if foo + > $ echo arthur + > arthur (bar !) + > #endif + > $ echo celeste + > celeste (foo !) + > $ echo zephir + > zephir (bar !) + > EOF + + $ rt test-conditional-matching.t + running 2 tests using 1 parallel processes + + --- $TESTTMP/anothertests/cases/test-conditional-matching.t + +++ $TESTTMP/anothertests/cases/test-conditional-matching.t#bar.err + @@ -3,11 +3,13 @@ + richtig (true !) + $ echo falsch + falsch (false !) + + falsch + #if foo + $ echo arthur + arthur \(bar !\) (re) + #endif + $ echo celeste + celeste \(foo !\) (re) + + celeste + $ echo zephir + zephir \(bar !\) (re) + + ERROR: test-conditional-matching.t#bar output changed + ! + --- $TESTTMP/anothertests/cases/test-conditional-matching.t + +++ $TESTTMP/anothertests/cases/test-conditional-matching.t#foo.err + @@ -3,11 +3,14 @@ + richtig (true !) + $ echo falsch + falsch (false !) + + falsch + #if foo + $ echo arthur + arthur \(bar !\) (re) + + arthur + #endif + $ echo celeste + celeste \(foo !\) (re) + $ echo zephir + zephir \(bar !\) (re) + + zephir + + ERROR: test-conditional-matching.t#foo output changed + ! + Failed test-conditional-matching.t#bar: output changed + Failed test-conditional-matching.t#foo: output changed + # Ran 2 tests, 0 skipped, 2 failed. + python hash seed: * (glob) + [1]