Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
Avoid perl in t1300-repo-config
author
Alex Riesen
<raa.lkml@gmail.com>
Wed, 27 Jun 2007 12:40:41 +0000
(14:40 +0200)
committer
Junio C Hamano
<gitster@pobox.com>
Fri, 29 Jun 2007 04:18:01 +0000
(21:18 -0700)
It fixes the test on system where ActiveState Perl is used.
Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t1300-repo-config.sh
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
7051c3b
)
diff --git
a/t/t1300-repo-config.sh
b/t/t1300-repo-config.sh
index 7a77bef4c0e7c24d263c87d59327bff1b8443aef..27486de4de40c7d2c44a318890040cd35c560379 100755
(executable)
--- a/
t/t1300-repo-config.sh
+++ b/
t/t1300-repo-config.sh
@@
-529,25
+529,23
@@
cat > .git/config <<\EOF
EOF
cat > expect <<\EOF
EOF
cat > expect <<\EOF
-Key: section.sub=section.val1
-Value: foo=bar
-Key: section.sub=section.val2
-Value: foo
-bar
-Key: section.sub=section.val3
-Value:
+section.sub=section.val1
+foo=barQsection.sub=section.val2
+foo
+barQsection.sub=section.val3
-Key: section.sub=section.val4
-Value:
-Key: section.sub=section.val5
+Qsection.sub=section.val4
+Qsection.sub=section.val5Q
EOF
EOF
-git config --null --list | perl -0ne 'chop;($key,$value)=split(/\n/,$_,2);print "Key: $key\n";print "Value: $value\n" if defined($value)' > result
+git config --null --list | tr '[\000]' 'Q' > result
+echo >>result
test_expect_success '--null --list' 'cmp result expect'
test_expect_success '--null --list' 'cmp result expect'
-git config --null --get-regexp 'val[0-9]' | perl -0ne 'chop;($key,$value)=split(/\n/,$_,2);print "Key: $key\n";print "Value: $value\n" if defined($value)' > result
+git config --null --get-regexp 'val[0-9]' | tr '[\000]' 'Q' > result
+echo >>result
test_expect_success '--null --get-regexp' 'cmp result expect'
test_expect_success '--null --get-regexp' 'cmp result expect'