From 63e5b5512226cfbea24bcf5d74b68cbc89197447 Mon Sep 17 00:00:00 2001 From: Linquize Date: Wed, 29 Jul 2015 00:08:37 +0800 Subject: [PATCH] index: add test for adding an old-style submodule to index --- tests/index/bypath.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tests/index/bypath.c b/tests/index/bypath.c index ddb766a22..b587a9ce8 100644 --- a/tests/index/bypath.c +++ b/tests/index/bypath.c @@ -33,3 +33,10 @@ void test_index_bypath__add_submodule(void) cl_git_pass(git_submodule_status(&status, g_repo, sm_name, 0)); cl_assert_equal_i(0, status & GIT_SUBMODULE_STATUS_WD_MODIFIED); } + +void test_index_bypath__add_submodule_old_style(void) +{ + const char *sm_name = "not-submodule"; + + cl_git_pass(git_index_add_bypath(g_idx, sm_name)); +}