Skip to content

Commit 8f757a2

Browse files
committed
test: Change default port for httpcore tests
The code previously used 9090 which is memorable enough to conflict with other code that could be running on developer machines. New default of 46406 is unlikely to hit such conflicts. Also, some small improvements in the httpcore bats script.
1 parent 78d2523 commit 8f757a2

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

agent/test/httpcore/httpcore.bats

100644100755
Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,14 @@
88
load '../helper'
99

1010
setup_file() {
11-
mkdir -p build/log
11+
agent_root="$BATS_TEST_DIRNAME/../.."
12+
mkdir -p "$agent_root/build/log"
1213

13-
export LOG="$(getcwd)/build/log/httpcore.log"
14-
export SERVER_PORT=9090
15-
export WS_URL=${WS_URL:-http://localhost:9090}
16-
cd test/httpcore
14+
export LOG="$agent_root/build/log/httpcore.log"
15+
export SERVER_PORT=46406
16+
export WS_URL=${WS_URL:-http://localhost:${SERVER_PORT}}
17+
18+
cd "$BATS_TEST_DIRNAME" || exit
1719
_configure_logging
1820

1921
printf 'getting set up' >&3

0 commit comments

Comments
 (0)