[PATCH 1 of 3] test-run-tests.t: add extra data to tests for keyword tests
Augie Fackler
raf at durin42.com
Tue Aug 5 15:22:31 UTC 2014
# HG changeset patch
# User Augie Fackler <raf at durin42.com>
# Date 1406595254 14400
# Mon Jul 28 20:54:14 2014 -0400
# Node ID ad790b3574a52375f62a628d0dab2892b229e3fe
# Parent c6e1f2c6d5f19538869338fa50ad519be6eb9b24
test-run-tests.t: add extra data to tests for keyword tests
This adds a fair amount of overall instability in the enclosing .t. As
such, this is performed in its own commit, and a test for --keyword on
run-tests.t will be added in a followup change.
diff --git a/tests/test-run-tests.t b/tests/test-run-tests.t
--- a/tests/test-run-tests.t
+++ b/tests/test-run-tests.t
@@ -13,6 +13,8 @@
$ cat > test-success.t << EOF
> $ echo babar
> babar
+ > $ echo xyzzy
+ > xyzzy
> EOF
$ $TESTDIR/run-tests.py --with-hg=`which hg`
@@ -25,16 +27,20 @@
$ cat > test-failure.t << EOF
> $ echo babar
> rataxes
+ > This is a noop statement so that
+ > this test is still more bytes than success.
> EOF
$ $TESTDIR/run-tests.py --with-hg=`which hg`
--- $TESTTMP/test-failure.t
+++ $TESTTMP/test-failure.t.err
- @@ -1,2 +1,2 @@
+ @@ -1,4 +1,4 @@
$ echo babar
- rataxes
+ babar
+ This is a noop statement so that
+ this test is still more bytes than success.
ERROR: test-failure.t output changed
!.
@@ -50,10 +56,12 @@
--- $TESTTMP/test-failure.t
+++ $TESTTMP/test-failure.t.err
- @@ -1,2 +1,2 @@
+ @@ -1,4 +1,4 @@
$ echo babar
- rataxes
+ babar
+ This is a noop statement so that
+ this test is still more bytes than success.
ERROR: test-failure.t output changed
!
@@ -77,10 +85,12 @@
--- $TESTTMP/test-failure.t
+++ $TESTTMP/test-failure.t.err
- @@ -1,2 +1,2 @@
+ @@ -1,4 +1,4 @@
$ echo babar
- rataxes
+ babar
+ This is a noop statement so that
+ this test is still more bytes than success.
ERROR: test-failure.t output changed
!
@@ -97,14 +107,18 @@
SALT* 0 0 (glob)
+ echo babar
babar
- + echo SALT* 2 0 (glob)
- SALT* 2 0 (glob)
+ + echo SALT* 4 0 (glob)
+ SALT* 4 0 (glob)
.+ echo SALT* 0 0 (glob)
SALT* 0 0 (glob)
+ echo babar
babar
+ echo SALT* 2 0 (glob)
SALT* 2 0 (glob)
+ + echo xyzzy
+ xyzzy
+ + echo SALT* 4 0 (glob)
+ SALT* 4 0 (glob)
.
# Ran 2 tests, 0 skipped, 0 warned, 0 failed.
@@ -118,19 +132,23 @@
--- $TESTTMP/test-failure*.t (glob)
+++ $TESTTMP/test-failure*.t.err (glob)
- @@ -1,2 +1,2 @@
+ @@ -1,4 +1,4 @@
$ echo babar
- rataxes
+ babar
+ This is a noop statement so that
+ this test is still more bytes than success.
ERROR: test-failure*.t output changed (glob)
!
--- $TESTTMP/test-failure*.t (glob)
+++ $TESTTMP/test-failure*.t.err (glob)
- @@ -1,2 +1,2 @@
+ @@ -1,4 +1,4 @@
$ echo babar
- rataxes
+ babar
+ This is a noop statement so that
+ this test is still more bytes than success.
ERROR: test-failure*.t output changed (glob)
!
@@ -156,10 +174,12 @@
--- $TESTTMP/test-failure.t
+++ $TESTTMP/test-failure.t.err
- @@ -1,2 +1,2 @@
+ @@ -1,4 +1,4 @@
$ echo babar
- rataxes
+ babar
+ This is a noop statement so that
+ this test is still more bytes than success.
Accept this change? [n]
ERROR: test-failure.t output changed
!.
@@ -171,6 +191,8 @@
$ cat test-failure.t
$ echo babar
rataxes
+ This is a noop statement so that
+ this test is still more bytes than success.
Accept the fix
@@ -178,16 +200,20 @@
--- $TESTTMP/test-failure.t
+++ $TESTTMP/test-failure.t.err
- @@ -1,2 +1,2 @@
+ @@ -1,4 +1,4 @@
$ echo babar
- rataxes
+ babar
+ This is a noop statement so that
+ this test is still more bytes than success.
Accept this change? [n] ..
# Ran 2 tests, 0 skipped, 0 warned, 0 failed.
$ cat test-failure.t
$ echo babar
babar
+ This is a noop statement so that
+ this test is still more bytes than success.
(reinstall)
$ mv backup test-failure.t
More information about the Mercurial-devel
mailing list