[PATCH 04/12] t0001: don't setup test repositories

John Keeping john at keeping.me.uk
Mon Apr 8 21:12:33 CEST 2013


This test doesn't use the test repositories, so it doesn't need them
created.

Signed-off-by: John Keeping <john at keeping.me.uk>
---
 tests/t0001-validate-git-versions.sh | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/tests/t0001-validate-git-versions.sh b/tests/t0001-validate-git-versions.sh
index 61c2062..9591d3e 100755
--- a/tests/t0001-validate-git-versions.sh
+++ b/tests/t0001-validate-git-versions.sh
@@ -1,19 +1,20 @@
 #!/bin/sh
 
 test_description='Check Git version is correct'
+CGIT_TEST_NO_CREATE_REPOS=YesPlease
 . ./setup.sh
 
 test_expect_success 'extract Git version from Makefile' '
 	sed -n -e "/^GIT_VER[ 	]*=/ {
 		s/^GIT_VER[ 	]*=[ 	]*//
 		p
-	}" ../../Makefile >trash/makefile_version
+	}" ../../Makefile >makefile_version
 '
 
 test_expect_success 'test Git version matches Makefile' '
 	( cat ../../git/GIT-VERSION-FILE || echo "No GIT-VERSION-FILE" ) |
-	sed -e "s/GIT_VERSION[ 	]*=[ 	]*//" >trash/git_version &&
-	diff -u trash/git_version trash/makefile_version
+	sed -e "s/GIT_VERSION[ 	]*=[ 	]*//" >git_version &&
+	diff -u git_version makefile_version
 '
 
 test_expect_success 'test submodule version matches Makefile' '
@@ -27,8 +28,8 @@ test_expect_success 'test submodule version matches Makefile' '
 				sed -e "s/^[0-9]* \\([0-9a-f]*\\) [0-9]	.*$/\\1/") &&
 			cd git &&
 			git describe --match "v[0-9]*" $sm_sha1
-		) | sed -e "s/^v//" >trash/sm_version &&
-		diff -u trash/sm_version trash/makefile_version
+		) | sed -e "s/^v//" >sm_version &&
+		diff -u sm_version makefile_version
 	fi
 '
 
-- 
1.8.2.694.ga76e9c3.dirty





More information about the CGit mailing list