git add currently goes past submodule boundaries.  Document this bug.

Signed-off-by: Ramkumar Ramachandra <artag...@gmail.com>
---
 t/t3700-add.sh | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/t/t3700-add.sh b/t/t3700-add.sh
index 874b3a6..a1ea050 100755
--- a/t/t3700-add.sh
+++ b/t/t3700-add.sh
@@ -310,4 +310,18 @@ test_expect_success 'git add --dry-run --ignore-missing of 
non-existing file out
        test_i18ncmp expect.err actual.err
 '
 
+test_expect_failure 'git add should not go past submodule boundaries' '
+       mkdir submodule_dir &&
+       (
+               cd submodule_dir &&
+               git init &&
+               cat >foo <<-\EOF &&
+               Some content
+               EOF
+               git add foo &&
+               git commit -a -m "Add foo"
+       ) &&
+       git add submodule_dir/foo
+'
+
 test_done
-- 
1.8.2.373.g961c512

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to