Skip to content

Commit 91f68d0

Browse files
authored
Merge pull request #271 from Julow/test-stable-user-agent
test: Fix unstable log output due to User-agent
2 parents e069a20 + 56957d7 commit 91f68d0

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

test/extensions/deflatemod.t/run.t

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
$ source ../../server-test-helpers.sh
22
$ run_server ./test.exe
33
ocsigen:main: [WARNING] Command pipe created
4-
ocsigen:access: connection for local-test from (curl/8.12.1): /index.html
4+
ocsigen:access: connection for local-test from (): /index.html
55
ocsigen:ext: [INFO] host found! local-test:0 matches .*
66
ocsigen:ext:staticmod: [INFO] Is it a static file?
77
ocsigen:local-file: [INFO] Testing "./index.html".
88
ocsigen:local-file: [INFO] checking if file index.html can be sent
99
ocsigen:ext: [INFO] Compiling exclusion regexp $^
1010
ocsigen:local-file: [INFO] Returning "./index.html".
11-
ocsigen:access: connection for local-test from (curl/8.12.1): /index.html
11+
ocsigen:access: connection for local-test from (): /index.html
1212
ocsigen:ext: [INFO] host found! local-test:0 matches .*
1313
ocsigen:ext:staticmod: [INFO] Is it a static file?
1414
ocsigen:local-file: [INFO] Testing "./index.html".

test/server-test-helpers.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ curl_ ()
3737
{
3838
local path=$1; shift
3939
# Remove the 'date' header, which is unreproducible
40-
curl --unix-socket ./local.sock -s -i "$@" "http://local-test/$path" | \
40+
curl --unix-socket ./local.sock --user-agent "" -s -i \
41+
"$@" "http://local-test/$path" | \
4142
grep -v "^date: "
4243
}

0 commit comments

Comments
 (0)