]> git.ipfire.org Git - thirdparty/git.git/commitdiff
t/README: mention test files are make targets
authorPhilippe Blain <levraiphilippeblain@gmail.com>
Sun, 24 Mar 2024 15:14:05 +0000 (15:14 +0000)
committerJunio C Hamano <gitster@pobox.com>
Mon, 25 Mar 2024 18:59:48 +0000 (11:59 -0700)
Since 23fc63bf8f (make tests ignorable with "make -i", 2005-11-08), each
test file defines a target in the test Makefile, such that one can
invoke:

make *checkout*

to run all tests with 'checkout' in their filename. This is useful to
run a subset of tests when you have a good idea of what part of the code
is touched by the changes your are testing.

Document that in t/README to help new (or more seasoned) contributors
that might not be aware.

Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/README

index 621d3b8c095441a8a8985b7f12363e26f8ab4d98..71211109338c05d423d7c74e4e3f77def6827a91 100644 (file)
--- a/t/README
+++ b/t/README
@@ -32,6 +32,13 @@ the tests.
     ok 2 - plain with GIT_WORK_TREE
     ok 3 - plain bare
 
+t/Makefile defines a target for each test file, such that you can also use
+shell pattern matching to run a subset of the tests:
+
+    make *checkout*
+
+will run all tests with 'checkout' in their filename.
+
 Since the tests all output TAP (see https://testanything.org) they can
 be run with any TAP harness. Here's an example of parallel testing
 powered by a recent version of prove(1):