##// END OF EJS Templates
test-serve: Show if port config and option are correctly used...
Thomas Arendsen Hein -
r10633:3318431f default
parent child Browse files
Show More
@@ -2,8 +2,10 b''
2
2
3 hgserve()
3 hgserve()
4 {
4 {
5 hg serve -a localhost -p $HGPORT1 -d --pid-file=hg.pid -E errors.log -v $@ \
5 hg serve -a localhost -d --pid-file=hg.pid -E errors.log -v $@ \
6 | sed -e 's/:[0-9][0-9]*//g' -e 's/http:\/\/[^/]*\//http:\/\/localhost\//'
6 | sed -e "s/:$HGPORT1\\([^0-9]\\)/:HGPORT1\1/g" \
7 -e "s/:$HGPORT2\\([^0-9]\\)/:HGPORT2\1/g" \
8 -e 's/http:\/\/[^/]*\//http:\/\/localhost\//'
7 cat hg.pid >> "$DAEMON_PIDS"
9 cat hg.pid >> "$DAEMON_PIDS"
8 echo % errors
10 echo % errors
9 cat errors.log
11 cat errors.log
@@ -17,6 +19,7 b' cd test'
17
19
18 echo '[web]' > .hg/hgrc
20 echo '[web]' > .hg/hgrc
19 echo 'accesslog = access.log' >> .hg/hgrc
21 echo 'accesslog = access.log' >> .hg/hgrc
22 echo "port = $HGPORT1" >> .hg/hgrc
20
23
21 echo % Without -v
24 echo % Without -v
22 hg serve -a localhost -p $HGPORT -d --pid-file=hg.pid -E errors.log
25 hg serve -a localhost -p $HGPORT -d --pid-file=hg.pid -E errors.log
@@ -30,6 +33,9 b' cat errors.log'
30 echo % With -v
33 echo % With -v
31 hgserve
34 hgserve
32
35
36 echo % With -v and -p HGPORT2
37 hgserve -p "$HGPORT2"
38
33 echo % With --prefix foo
39 echo % With --prefix foo
34 hgserve --prefix foo
40 hgserve --prefix foo
35
41
@@ -2,17 +2,20 b''
2 access log created - .hg/hgrc respected
2 access log created - .hg/hgrc respected
3 % errors
3 % errors
4 % With -v
4 % With -v
5 listening at http://localhost/ (bound to 127.0.0.1)
5 listening at http://localhost/ (bound to 127.0.0.1:HGPORT1)
6 % errors
7 % With -v and -p HGPORT2
8 listening at http://localhost/ (bound to 127.0.0.1:HGPORT2)
6 % errors
9 % errors
7 % With --prefix foo
10 % With --prefix foo
8 listening at http://localhost/foo/ (bound to 127.0.0.1)
11 listening at http://localhost/foo/ (bound to 127.0.0.1:HGPORT1)
9 % errors
12 % errors
10 % With --prefix /foo
13 % With --prefix /foo
11 listening at http://localhost/foo/ (bound to 127.0.0.1)
14 listening at http://localhost/foo/ (bound to 127.0.0.1:HGPORT1)
12 % errors
15 % errors
13 % With --prefix foo/
16 % With --prefix foo/
14 listening at http://localhost/foo/ (bound to 127.0.0.1)
17 listening at http://localhost/foo/ (bound to 127.0.0.1:HGPORT1)
15 % errors
18 % errors
16 % With --prefix /foo/
19 % With --prefix /foo/
17 listening at http://localhost/foo/ (bound to 127.0.0.1)
20 listening at http://localhost/foo/ (bound to 127.0.0.1:HGPORT1)
18 % errors
21 % errors
General Comments 0
You need to be logged in to leave comments. Login now