Skip to content

Commit 46c9f26

Browse files
committed
Add a test.
Verified that this breaks before the fix and passes afterwards.
1 parent 786c647 commit 46c9f26

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

tests/network/refspecs.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,10 @@ void test_network_refspecs__transform_mid_star(void)
111111
assert_valid_transform("refs/*:refs/*", "refs/heads/master", "refs/heads/master");
112112
}
113113

114+
void test_network_refspecs__no_dst(void) {
115+
assert_valid_transform("refs/heads/master:", "refs/heads/master", "");
116+
}
117+
114118
static void assert_invalid_transform(const char *refspec, const char *name)
115119
{
116120
git_refspec spec;

0 commit comments

Comments
 (0)