mirror of
https://github.com/emikulic/darkhttpd.git
synced 2023-08-10 21:13:08 +03:00
Add test for --forward
This commit is contained in:
13
devel/cover
13
devel/cover
@ -21,12 +21,23 @@ mkdir $DIR || exit 1
|
||||
rm -f darkhttpd.gcda darkhttpd.log
|
||||
# display usage statement
|
||||
./a.out >/dev/null
|
||||
# run all tests against this instance (generates darkhttpd.gcda)
|
||||
|
||||
# run tests against a basic instance (generates darkhttpd.gcda)
|
||||
./a.out $DIR --port $PORT --log darkhttpd.log &
|
||||
PID=$!
|
||||
kill -0 $PID || exit 1
|
||||
python test.py
|
||||
kill $PID
|
||||
|
||||
# run forward tests
|
||||
./a.out $DIR --port $PORT \
|
||||
--forward example.com http://www.example.com \
|
||||
--forward secure.example.com https://www.example.com/secure &
|
||||
PID=$!
|
||||
kill -0 $PID || exit 1
|
||||
python test_forward.py
|
||||
kill $PID
|
||||
|
||||
echo generating darkhttpd.c.gcov report
|
||||
gcov darkhttpd
|
||||
rm -rf $DIR
|
||||
|
Reference in New Issue
Block a user