Skip to contentSkip to conversation

Make t5710 more strict when creating nested repos

PATCH New Alex Riesen 1 participant 1 message Jun 15, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Make t5710 more strict when creating nested repos

The test 'creating too deep nesting' can fail even when cloning the repos, but is not its main purpose (it has to prepare nested repos and ensure the last one is invalid). So split the test into the creation and invalidity checking parts.

---

Noticed try to figure out why the test breaks on cygwin with the recent in-core-index branch. Didn't manage that, though.

 t/t5710-info-alternate.sh |   12 ++++++++----
 1 files changed, 8 insertions(+), 4 deletions(-)
t/t5710-info-alternate.sh +8 -4
index 699df6e..1908dc8 100755
@@ -53,14 +53,18 @@ git prune'
 
 cd "$base_dir"
 
-test_expect_failure 'creating too deep nesting' \
+test_expect_success 'creating too deep nesting' \
 'git clone -l -s C D &&
 git clone -l -s D E &&
 git clone -l -s E F &&
 git clone -l -s F G &&
-git clone -l -s G H &&
-cd H &&
-test_valid_repo'
+git clone -l -s G H'
+
+test_expect_success 'invalidity of deepest repository' \
+'cd H && {
+	test_valid_repo
+	test $? -ne 0
+}'
 
 cd "$base_dir"
 
Signature · 1 line
1.5.4.rc3.49.gd0cc3