Show More
@@ -1,53 +1,53 | |||||
1 | #!/bin/sh |
|
1 | #!/bin/sh | |
2 | # An attempt at more fully testing the hgweb web interface. |
|
2 | # An attempt at more fully testing the hgweb web interface. | |
3 | # The following things are tested elsewhere and are therefore omitted: |
|
3 | # The following things are tested elsewhere and are therefore omitted: | |
4 | # - archive, tested in test-archive |
|
4 | # - archive, tested in test-archive | |
5 | # - unbundle, tested in test-push-http |
|
5 | # - unbundle, tested in test-push-http | |
6 | # - changegroupsubset, tested in test-pull |
|
6 | # - changegroupsubset, tested in test-pull | |
7 |
|
7 | |||
8 | echo % Set up the repo |
|
8 | echo % Set up the repo | |
9 | hg init test |
|
9 | hg init test | |
10 | cd test |
|
10 | cd test | |
11 | mkdir da |
|
11 | mkdir da | |
12 | echo foo > da/foo |
|
12 | echo foo > da/foo | |
13 | echo foo > foo |
|
13 | echo foo > foo | |
14 | hg ci -d'0 0' -Ambase |
|
14 | hg ci -d'0 0' -Ambase | |
15 | hg tag 1.0 |
|
15 | hg tag 1.0 | |
16 | hg serve -n test -p $HGPORT -d --pid-file=hg.pid -E errors.log |
|
16 | hg serve -n test -p $HGPORT -d --pid-file=hg.pid -E errors.log | |
17 | cat hg.pid >> $DAEMON_PIDS |
|
17 | cat hg.pid >> $DAEMON_PIDS | |
18 |
|
18 | |||
19 | echo % Logs and changes |
|
19 | echo % Logs and changes | |
20 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/log/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" |
|
20 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/log/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" | |
21 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/log/1/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" |
|
21 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/log/1/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" | |
22 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/log/1/foo/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" |
|
22 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/log/1/foo/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" | |
23 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/shortlog/' | sed "s/[0-9]* years/many years/" |
|
23 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/shortlog/' | sed "s/[0-9]* years/many years/" | |
24 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/rev/1/?style=raw' |
|
24 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/rev/1/?style=raw' | |
25 |
|
25 | |||
26 | echo % File-related |
|
26 | echo % File-related | |
27 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/file/1/foo/?style=raw' |
|
27 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/file/1/foo/?style=raw' | |
28 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/annotate/1/foo/?style=raw' |
|
28 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/annotate/1/foo/?style=raw' | |
29 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/file/1/?style=raw' |
|
29 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/file/1/?style=raw' | |
30 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/filediff/1/foo/?style=raw' |
|
30 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/filediff/1/foo/?style=raw' | |
31 |
|
31 | |||
32 | echo % Overviews |
|
32 | echo % Overviews | |
33 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/tags/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" |
|
33 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/tags/?style=atom' | sed "s/http:\/\/[^/]*\//http:\/\/127.0.0.1\//" | |
34 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/summary/?style=gitweb' | sed "s/[0-9]* years ago/long ago/" |
|
34 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/summary/?style=gitweb' | sed "s/[0-9]* years ago/long ago/g" | |
35 |
|
35 | |||
36 | echo % capabilities |
|
36 | echo % capabilities | |
37 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/capabilities' |
|
37 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/capabilities' | |
38 | echo % heads |
|
38 | echo % heads | |
39 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/heads' |
|
39 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/heads' | |
40 | echo % lookup |
|
40 | echo % lookup | |
41 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/lookup/1' |
|
41 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/lookup/1' | |
42 | echo % branches |
|
42 | echo % branches | |
43 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/branches' |
|
43 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/branches' | |
44 | echo % changegroup |
|
44 | echo % changegroup | |
45 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/changegroup' |
|
45 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/changegroup' | |
46 | echo % stream_out |
|
46 | echo % stream_out | |
47 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/stream_out' |
|
47 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/stream_out' | |
48 |
|
48 | |||
49 | echo % Static files |
|
49 | echo % Static files | |
50 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/static/style.css' |
|
50 | "$TESTDIR/get-with-headers.py" 127.0.0.1:$HGPORT '/static/style.css' | |
51 |
|
51 | |||
52 | echo % ERRORS ENCOUNTERED |
|
52 | echo % ERRORS ENCOUNTERED | |
53 | cat errors.log |
|
53 | cat errors.log |
1 | NO CONTENT: modified file, binary diff hidden |
|
NO CONTENT: modified file, binary diff hidden |
General Comments 0
You need to be logged in to leave comments.
Login now