]> git.ipfire.org Git - thirdparty/git.git/commitdiff
submodule add: test failure when url is not configured in superproject
authorJens Lehmann <Jens.Lehmann@web.de>
Mon, 6 Jun 2011 19:57:01 +0000 (21:57 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 6 Jun 2011 20:46:35 +0000 (13:46 -0700)
This documents the current behavior (submodule add with the url set in the
superproject is already tested in t7403, t7406, t7407 and t7506).

Signed-off-by: Jens Lehmann <Jens.Lehmann@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t7400-submodule-basic.sh

index 874279e32da98ac2c20137a207a0d115f073e444..cae5fd012c3c9f9f0b020bb6d5b274e5adfe4478 100755 (executable)
@@ -446,6 +446,13 @@ test_expect_success 'add should fail when path is used by an existing directory'
        )
 '
 
+test_expect_success 'add should fail when path is relative but no url is set in the superproject' '
+       (
+               cd addtest &&
+               test_must_fail git submodule add ../repo relative
+       )
+'
+
 test_expect_success 'set up for relative path tests' '
        mkdir reltest &&
        (