comparison tests/test-hgwebdir.t @ 31008:636cf3f7620d

tests: use LOCALIP This patch replaces hardcoded 127.0.0.1 with $LOCALIP in all tests. Till now, the IPv6 series should make tests pass on common IPv6 systems where the local device has the address "::1" and the hostname "localhost" resolves to "::1".
author Jun Wu <quark@fb.com>
date Thu, 16 Feb 2017 09:38:52 -0800
parents eb7de21b15be
children da7d19324b1e
comparison
equal deleted inserted replaced
31007:bfdb0741f9f2 31008:636cf3f7620d
1419 > address = localhost 1419 > address = localhost
1420 > port = $HGPORT1 1420 > port = $HGPORT1
1421 > EOF 1421 > EOF
1422 $ hg serve -d --pid-file=hg.pid --web-conf paths.conf \ 1422 $ hg serve -d --pid-file=hg.pid --web-conf paths.conf \
1423 > -A access-paths.log -E error-paths-9.log 1423 > -A access-paths.log -E error-paths-9.log
1424 listening at http://*:$HGPORT1/ (bound to 127.0.0.1:$HGPORT1) (glob) 1424 listening at http://*:$HGPORT1/ (bound to *$LOCALIP*:$HGPORT1) (glob)
1425 $ cat hg.pid >> $DAEMON_PIDS 1425 $ cat hg.pid >> $DAEMON_PIDS
1426 $ get-with-headers.py localhost:$HGPORT1 '?style=raw' 1426 $ get-with-headers.py localhost:$HGPORT1 '?style=raw'
1427 200 Script output follows 1427 200 Script output follows
1428 1428
1429 1429
1431 test --port option overrides web.port: 1431 test --port option overrides web.port:
1432 1432
1433 $ killdaemons.py 1433 $ killdaemons.py
1434 $ hg serve -p $HGPORT2 -d -v --pid-file=hg.pid --web-conf paths.conf \ 1434 $ hg serve -p $HGPORT2 -d -v --pid-file=hg.pid --web-conf paths.conf \
1435 > -A access-paths.log -E error-paths-10.log 1435 > -A access-paths.log -E error-paths-10.log
1436 listening at http://*:$HGPORT2/ (bound to 127.0.0.1:$HGPORT2) (glob) 1436 listening at http://*:$HGPORT2/ (bound to *$LOCALIP*:$HGPORT2) (glob)
1437 $ cat hg.pid >> $DAEMON_PIDS 1437 $ cat hg.pid >> $DAEMON_PIDS
1438 $ get-with-headers.py localhost:$HGPORT2 '?style=raw' 1438 $ get-with-headers.py localhost:$HGPORT2 '?style=raw'
1439 200 Script output follows 1439 200 Script output follows
1440 1440
1441 1441