Thread (11 messages) flat view 11 messages, 2 authors, 2016-06-15
DORMANTno replies

Revision v1 of 2 in this series.

Revisions (2)
  1. v1 current
  2. v2 [diff vs current]

[PATCH 8/8] t/README: Document the dangers of printing "ok" / "not ok"

From: Ævar Arnfjörð Bjarmason <hidden>
Date: 2016-06-15 22:49:03
Subsystem: the rest · Maintainer: Linus Torvalds

A TAP harness will get confused if you print "ok" or "not ok" at the
beginning of a line. This had to be fixed in
335f87871fe5aa6b3fd55b2b4e80f16fe9681483 when TAP support was
introduced.

Signed-off-by: Ævar Arnfjörð Bjarmason <redacted>
---
 t/README |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/t/README b/t/README
index 42a4c25..29f795e 100644
--- a/t/README
+++ b/t/README
@@ -50,6 +50,12 @@ prove and other harnesses come with a lot of useful options. The
     # Repeat until no more failures
     $ prove -j 15 --state=failed,save ./t[0-9]*.sh
 
+The TAP support is completely incidental. A TAP harness is just a
+program that interprets the "ok"/"not ok" (and some other strings) in
+a special way. The only limitation this imposes is that you shouldn't
+echo "ok" or "not ok" by yourself at the beginning of a line, that'll
+confuse the TAP harness.
+
 You can also run each test individually from command line, like this:
 
     $ ./t3010-ls-files-killed-modified.sh
-- 
1.7.1.251.g92a7
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help