Skip to content

Commit af83baf

Browse files
KarthikNayakgitster
authored andcommitted
t6302: for-each-ref tests for ref-filter APIs
Add a test suite for testing the ref-filter APIs used by for-each-ref. We just intialize the test suite for now. More tests will be added in the following patches as more options are added to for-each-ref. Based-on-patch-by: Jeff King <[email protected]> Mentored-by: Christian Couder <[email protected]> Mentored-by: Matthieu Moy <[email protected]> Signed-off-by: Karthik Nayak <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 1958a6e commit af83baf

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

t/t6302-for-each-ref-filter.sh

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
#!/bin/sh
2+
3+
test_description='test for-each-refs usage of ref-filter APIs'
4+
5+
. ./test-lib.sh
6+
. "$TEST_DIRECTORY"/lib-gpg.sh
7+
8+
if ! test_have_prereq GPG
9+
then
10+
skip_all="skipping for-each-ref tests, GPG not available"
11+
test_done
12+
fi
13+
14+
test_expect_success 'setup some history and refs' '
15+
test_commit one &&
16+
test_commit two &&
17+
test_commit three &&
18+
git checkout -b side &&
19+
test_commit four &&
20+
git tag -s -m "A signed tag message" signed-tag &&
21+
git tag -s -m "Annonated doubly" double-tag signed-tag &&
22+
git checkout master &&
23+
git update-ref refs/odd/spot master
24+
'
25+
26+
test_done

0 commit comments

Comments
 (0)