fix this damn non determinism test

This commit is contained in:
Simon Cruanes 2024-06-20 11:02:06 -04:00
parent ee637c7c81
commit f720a01ed8
No known key found for this signature in database
GPG key ID: EBFFF6F283F3A2B4

View file

@ -15,7 +15,10 @@ sleep 0.1
curl -N "http://localhost:${PORT}/vfs/a.txt" --max-time 5 curl -N "http://localhost:${PORT}/vfs/a.txt" --max-time 5
sleep 0.1 sleep 0.1
curl -N "http://localhost:${PORT}/vfs/a.txt" -H 'accept-encoding: deflate' --max-time 5 | base64 # NOTE: the sed is there because of a timing/deflate non determinism. Both strings
# decompress to the same "hello\nworld\n" but which one is picked depends on
# the machine/library/… ?? but both are valid.
curl -N "http://localhost:${PORT}/vfs/a.txt" -H 'accept-encoding: deflate' --max-time 5 | base64 | sed 's+ykjNycnnKs8vyknhAgAAAP//AwA=+ykjNycnnKs8vyknhAgAAAP//+'
sleep 0.1 sleep 0.1
curl -N "http://localhost:${PORT}/vfs/sub/yolo.html" --max-time 5 curl -N "http://localhost:${PORT}/vfs/sub/yolo.html" --max-time 5