t4016-*.sh: Skip all tests rather than each test

Each test in this file is skipped if the TABS_IN_FILENAMES test prerequisite is set. Use the 'skip_all' facility at the head of the file to skip all of the tests instead. Signed-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Ramsay Jones committed Sep 1, 2012 at 19:10 UTC 69915d88bca0cb6837c68ca09b702ad051f207e7
1 file changed +9 -11
t/t4016-diff-quote.sh
+9 -11
@@ -13,14 +13,12 @@ P1='pathname with HT'
13 P2='pathname with SP'
14 P3='pathname
15 with LF'
16 -if : 2>/dev/null >"$P1" && test -f "$P1" && rm -f "$P1"
17 -then
18 - test_set_prereq TABS_IN_FILENAMES
19 -else
20 - say 'Your filesystem does not allow tabs in filenames'
21 -fi
16 +echo 2>/dev/null >"$P1" && test -f "$P1" && rm -f "$P1" || {
17 + skip_all='Your filesystem does not allow tabs in filenames'
18 + test_done
19 +}
20
23 -test_expect_success TABS_IN_FILENAMES setup '
21 +test_expect_success setup '
22 echo P0.0 >"$P0.0" &&
23 echo P0.1 >"$P0.1" &&
24 echo P0.2 >"$P0.2" &&
@@ -40,7 +38,7 @@ test_expect_success TABS_IN_FILENAMES setup '
38 :
39 '
40
43 -test_expect_success TABS_IN_FILENAMES 'setup expected files' '
41 +test_expect_success 'setup expected files' '
42 cat >expect <<\EOF
43 rename pathname.1 => "Rpathname\twith HT.0" (100%)
44 rename pathname.3 => "Rpathname\nwith LF.0" (100%)
@@ -52,12 +50,12 @@ cat >expect <<\EOF
50 EOF
51 '
52
55 -test_expect_success TABS_IN_FILENAMES 'git diff --summary -M HEAD' '
53 +test_expect_success 'git diff --summary -M HEAD' '
54 git diff --summary -M HEAD >actual &&
55 test_cmp expect actual
56 '
57
60 -test_expect_success TABS_IN_FILENAMES 'git diff --numstat -M HEAD' '
58 +test_expect_success 'git diff --numstat -M HEAD' '
59 cat >expect <<-\EOF &&
60 0 0 pathname.1 => "Rpathname\twith HT.0"
61 0 0 pathname.3 => "Rpathname\nwith LF.0"
@@ -71,7 +69,7 @@ test_expect_success TABS_IN_FILENAMES 'git diff --numstat -M HEAD' '
69 test_cmp expect actual
70 '
71
74 -test_expect_success TABS_IN_FILENAMES 'git diff --stat -M HEAD' '
72 +test_expect_success 'git diff --stat -M HEAD' '
73 cat >expect <<-\EOF &&
74 pathname.1 => "Rpathname\twith HT.0" | 0
75 pathname.3 => "Rpathname\nwith LF.0" | 0