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

Revision v1 of 3 in this series.

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

[PATCH 5/8] t/README: Document test_external*

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

There was do documentation for the test_external_without_stderr and
test_external functions.

Signed-off-by: Ævar Arnfjörð Bjarmason <redacted>
---
 t/README |   27 +++++++++++++++++++++++++++
 1 files changed, 27 insertions(+), 0 deletions(-)
diff --git a/t/README b/t/README
index 67f8f30..43d6d4d 100644
--- a/t/README
+++ b/t/README
@@ -329,6 +329,33 @@ library for your script to use.
 	    skip_all='skipping perl interface tests, perl not available'
 	    test_done
 	fi
+    
+ - test_external [<prereq>] <message> <external> <script>
+ 
+   Execute a <script> with an <external> interpreter (like perl). This
+   was added for tests like t9700-perl-git.sh which do most of their
+   work in an external test script.
+   
+	test_external_without_stderr \
+	    'Perl API' \
+	    "$PERL_PATH" "$TEST_DIRECTORY"/t9700/test.pl
+
+   If the test is outputting its own TAP you should set the
+   test_external_has_tap variable somewhere before calling the first
+   test_external* function. See t9700-perl-git.sh for an example.
+
+	# The external test will outputs its own plan
+	test_external_has_tap=1
+    
+ - test_external_without_stderr [<prereq>] <message> <external> <script>
+ 
+   Like test_external but fail if there's any output on stderr,
+   instead of checking the exit code.
+ 
+	test_external_without_stderr \
+	    'Perl API' \
+	    "$PERL_PATH" "$TEST_DIRECTORY"/t9700/test.pl
+
 
 Tips for Writing Tests
 ----------------------
-- 
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