Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
remote-bzr: simplify test checks
author
Felipe Contreras
<felipe.contreras@gmail.com>
Sat, 25 May 2013 02:29:36 +0000
(21:29 -0500)
committer
Junio C Hamano
<gitster@pobox.com>
Tue, 28 May 2013 14:59:31 +0000
(07:59 -0700)
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/remote-helpers/test-bzr.sh
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
9f36d61
)
diff --git
a/contrib/remote-helpers/test-bzr.sh
b/contrib/remote-helpers/test-bzr.sh
index f215b26bac9f65d81ff1b6ad440b2df40d1ef922..dce281f91195cde4937b935910ec73f597bb826a 100755
(executable)
--- a/
contrib/remote-helpers/test-bzr.sh
+++ b/
contrib/remote-helpers/test-bzr.sh
@@
-18,15
+18,8
@@
if ! python -c 'import bzrlib'; then
fi
check () {
fi
check () {
- (
- cd $1 &&
- git log --format='%s' -1 &&
- git symbolic-ref HEAD
- ) > actual &&
- (
- echo $2 &&
- echo "refs/heads/$3"
- ) > expected &&
+ echo $3 > expected &&
+ git --git-dir=$1/.git log --format='%s' -1 $2 > actual
test_cmp expected actual
}
test_cmp expected actual
}
@@
-42,7
+35,7
@@
test_expect_success 'cloning' '
) &&
git clone "bzr::bzrrepo" gitrepo &&
) &&
git clone "bzr::bzrrepo" gitrepo &&
- check gitrepo
one master
+ check gitrepo
HEAD one
'
test_expect_success 'pulling' '
'
test_expect_success 'pulling' '
@@
-54,7
+47,7
@@
test_expect_success 'pulling' '
(cd gitrepo && git pull) &&
(cd gitrepo && git pull) &&
- check gitrepo
two master
+ check gitrepo
HEAD two
'
test_expect_success 'pushing' '
'
test_expect_success 'pushing' '
@@
-89,7
+82,7
@@
test_expect_success 'roundtrip' '
(cd gitrepo && git pull && git push) &&
(cd gitrepo && git pull && git push) &&
- check gitrepo
four maste
r &&
+ check gitrepo
HEAD fou
r &&
(
cd gitrepo &&
(
cd gitrepo &&