action/test2
author Paul Crowley <paul@lshift.net>
Tue, 15 Dec 2009 14:28:27 +0000
changeset 269 a09f1bc9a6cf
parent 268 24145a4eb6fc
child 270 28b355b7390e
permissions -rwxr-xr-x
Change back to non-Debian testing, fix test to work around NULL problem

#!/bin/sh

set -e

cd

cat > .ssh/config <<__END__
Host chroothg
Hostname localhost
User hg
Port 2222
__END__

echo "Pulling real project"
hg clone ssh://chroothg/real/project
cd project
echo "and I'm adding something" >> allowedhere/content
hg commit -u test2 -m "Added something to the file"
echo "This push should succeed"
hg push
echo "And it did"
echo "This should fail" >> cantwrite
hg commit -u test2 -m "WONTPUSH"
# Fail only if this succeeds
echo "About to do bad push"
hg push && false
echo "OK, checking that didn't push"
hg outgoing --template '{desc}'
echo "really checking now"
hg outgoing --template '{desc}' | grep -q WONTPUSH
echo "done"