Skip to content

Commit f46c243

Browse files
Denton-Lgitster
authored andcommitted
t0003: don't use test_must_fail attr_check
In an effort to remove test_must_fail for all invocations not related to git or test-tool, replace invocations of `test_must_fail attr_check` with a plain attr_check call with the $expect argument set to the actual value output by git. Signed-off-by: Denton Liu <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 99c049b commit f46c243

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

t/t0003-attributes.sh

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ attr_check_quote () {
2424

2525
test_expect_success 'open-quoted pathname' '
2626
echo "\"a test=a" >.gitattributes &&
27-
test_must_fail attr_check a a
27+
attr_check a unspecified
2828
'
2929

3030

@@ -109,20 +109,20 @@ test_expect_success 'attribute test' '
109109

110110
test_expect_success 'attribute matching is case sensitive when core.ignorecase=0' '
111111
112-
test_must_fail attr_check F f "-c core.ignorecase=0" &&
113-
test_must_fail attr_check a/F f "-c core.ignorecase=0" &&
114-
test_must_fail attr_check a/c/F f "-c core.ignorecase=0" &&
115-
test_must_fail attr_check a/G a/g "-c core.ignorecase=0" &&
116-
test_must_fail attr_check a/B/g a/b/g "-c core.ignorecase=0" &&
117-
test_must_fail attr_check a/b/G a/b/g "-c core.ignorecase=0" &&
118-
test_must_fail attr_check a/b/H a/b/h "-c core.ignorecase=0" &&
119-
test_must_fail attr_check a/b/D/g "a/b/d/*" "-c core.ignorecase=0" &&
120-
test_must_fail attr_check oNoFf unset "-c core.ignorecase=0" &&
121-
test_must_fail attr_check oFfOn set "-c core.ignorecase=0" &&
112+
attr_check F unspecified "-c core.ignorecase=0" &&
113+
attr_check a/F unspecified "-c core.ignorecase=0" &&
114+
attr_check a/c/F unspecified "-c core.ignorecase=0" &&
115+
attr_check a/G unspecified "-c core.ignorecase=0" &&
116+
attr_check a/B/g a/g "-c core.ignorecase=0" &&
117+
attr_check a/b/G unspecified "-c core.ignorecase=0" &&
118+
attr_check a/b/H unspecified "-c core.ignorecase=0" &&
119+
attr_check a/b/D/g a/g "-c core.ignorecase=0" &&
120+
attr_check oNoFf unspecified "-c core.ignorecase=0" &&
121+
attr_check oFfOn unspecified "-c core.ignorecase=0" &&
122122
attr_check NO unspecified "-c core.ignorecase=0" &&
123-
test_must_fail attr_check a/b/D/NO "a/b/d/*" "-c core.ignorecase=0" &&
123+
attr_check a/b/D/NO unspecified "-c core.ignorecase=0" &&
124124
attr_check a/b/d/YES a/b/d/* "-c core.ignorecase=0" &&
125-
test_must_fail attr_check a/E/f "A/e/F" "-c core.ignorecase=0"
125+
attr_check a/E/f f "-c core.ignorecase=0"
126126
127127
'
128128

@@ -146,8 +146,8 @@ test_expect_success 'attribute matching is case insensitive when core.ignorecase
146146
'
147147

148148
test_expect_success CASE_INSENSITIVE_FS 'additional case insensitivity tests' '
149-
test_must_fail attr_check a/B/D/g "a/b/d/*" "-c core.ignorecase=0" &&
150-
test_must_fail attr_check A/B/D/NO "a/b/d/*" "-c core.ignorecase=0" &&
149+
attr_check a/B/D/g a/g "-c core.ignorecase=0" &&
150+
attr_check A/B/D/NO unspecified "-c core.ignorecase=0" &&
151151
attr_check A/b/h a/b/h "-c core.ignorecase=1" &&
152152
attr_check a/B/D/g "a/b/d/*" "-c core.ignorecase=1" &&
153153
attr_check A/B/D/NO "a/b/d/*" "-c core.ignorecase=1"

0 commit comments

Comments
 (0)