git-svn: tests no longer fail if LC_ALL is not a UTF-8 locale
Signed-off-by: Eric Wong <normalperson@yhbt.net>
Eric Wong committed
Jun 15, 2006 at 19:13 UTC
86f363791b281fb916414a89282b2e67cdaa36c0
2 files changed
+9
-4
contrib/git-svn/Makefile
+3
-2
@@ -32,9 +32,10 @@ test: git-svn
32
cd t && $(SHELL) ./t0000-contrib-git-svn.sh $(TEST_FLAGS)
33
cd t && $(SHELL) ./t0001-contrib-git-svn-props.sh $(TEST_FLAGS)
34
35
+# we can test NO_OPTIMIZE_COMMITS independently of LC_ALL
36
full-test:
36
- $(MAKE) test GIT_SVN_NO_LIB=1 GIT_SVN_NO_OPTIMIZE_COMMITS=1
37
- $(MAKE) test GIT_SVN_NO_LIB=0 GIT_SVN_NO_OPTIMIZE_COMMITS=1
37
+ $(MAKE) test GIT_SVN_NO_LIB=1 GIT_SVN_NO_OPTIMIZE_COMMITS=1 LC_ALL=C
38
+ $(MAKE) test GIT_SVN_NO_LIB=0 GIT_SVN_NO_OPTIMIZE_COMMITS=1 LC_ALL=C
39
$(MAKE) test GIT_SVN_NO_LIB=1 GIT_SVN_NO_OPTIMIZE_COMMITS=0 \
40
LC_ALL=en_US.UTF-8
41
$(MAKE) test GIT_SVN_NO_LIB=0 GIT_SVN_NO_OPTIMIZE_COMMITS=0 \
contrib/git-svn/t/t0000-contrib-git-svn.sh
+6
-2
@@ -194,8 +194,12 @@ test_expect_success "$name" \
194
diff -u a b"
195
196
name='check imported tree checksums expected tree checksums'
197
-cat > expected <<\EOF
198
-tree f735671b89a7eb30cab1d8597de35bd4271ab813
197
+rm -f expected
198
+if test -n "$GIT_SVN_LC_ALL" && echo $GIT_SVN_LC_ALL | grep -q '\.UTF-8$'
199
+then
200
+ echo tree f735671b89a7eb30cab1d8597de35bd4271ab813 > expected
201
+fi
202
+cat >> expected <<\EOF
203
tree 4b9af72bb861eaed053854ec502cf7df72618f0f
204
tree 031b8d557afc6fea52894eaebb45bec52f1ba6d1
205
tree 0b094cbff17168f24c302e297f55bfac65eb8bd3