tests/test-hgweb
author Patrick Mezard <pmezard@gmail.com>
Sat, 14 Jul 2007 18:34:06 +0200
changeset 4881 c51c9bc4579d
parent 3936 8eccfce0ab5e
child 5384 e3a0c092b4e2
permissions -rwxr-xr-x
Add hghave utility and run-tests.py support. hghave detects system features like symlinks availability at run-time. Tests can be skipped by starting them with: "$TESTDIR/hghave" symlink || exit 80 The 80 exit status triggers hghave output handling by run-tests.py. Also, tests output can be locally patched on the fly to match reference output.

#!/bin/sh

hg init test
cd test
mkdir da
echo foo > da/foo
echo foo > foo
hg ci -Ambase -d '0 0'
hg serve -p 20060 -d --pid-file=hg.pid
echo % manifest
("$TESTDIR/get-with-headers.py" localhost:20060 '/file/tip/?style=raw')
("$TESTDIR/get-with-headers.py" localhost:20060 '/file/tip/da?style=raw')
kill `cat hg.pid`