Avoid perl in t1300-repo-config
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>
Alex Riesen committed
Jun 27, 2007 at 14:40 UTC
2b9a50208f2664d228b238affd8496d4d9677d56
1 file changed
+10
-12
t/t1300-repo-config.sh
+10
-12
@@ -529,25 +529,23 @@ cat > .git/config <<\EOF
529
EOF
530
531
cat > expect <<\EOF
532
-Key: section.sub=section.val1
533
-Value: foo=bar
534
-Key: section.sub=section.val2
535
-Value: foo
536
-bar
537
-Key: section.sub=section.val3
538
-Value:
532
+section.sub=section.val1
533
+foo=barQsection.sub=section.val2
534
+foo
535
+barQsection.sub=section.val3
536
537
541
-Key: section.sub=section.val4
542
-Value:
543
-Key: section.sub=section.val5
538
+Qsection.sub=section.val4
539
+Qsection.sub=section.val5Q
540
EOF
541
546
-git config --null --list | perl -0ne 'chop;($key,$value)=split(/\n/,$_,2);print "Key: $key\n";print "Value: $value\n" if defined($value)' > result
542
+git config --null --list | tr '[\000]' 'Q' > result
543
+echo >>result
544
545
test_expect_success '--null --list' 'cmp result expect'
546
550
-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
547
+git config --null --get-regexp 'val[0-9]' | tr '[\000]' 'Q' > result
548
+echo >>result
549
550
test_expect_success '--null --get-regexp' 'cmp result expect'
551