blob 7ca450a9a183f6d4050d7b7d97b1db969b6f03c9 949 bytes (raw)
name: t/t9001-sendfile-to-path.sh # note: path name is non-authoritative(*)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
| | #!/bin/sh
. ./test-lib.sh
skip_models StreamResponseEpoll
t_plan 6 "Sendfile middleware test for $model"
t_begin "configure and start" && {
rtmpfiles curl_err
rainbows_setup
# do not allow default middleware to be loaded since it may
# kill body#to_path
rainbows -E none -D t9001.ru -c $unicorn_config
rainbows_wait_start
random_blob_sha1=$(rsha1 < random_blob)
}
t_begin "hit with curl" && {
sha1=$(curl -sSfv http://$listen/ 2> $curl_err | rsha1)
}
t_begin "kill server" && {
kill $rainbows_pid
}
t_begin "SHA1 matches source" && {
test x$random_blob_sha1 = x$sha1
}
t_begin "no errors in Rainbows! stderr" && {
check_stderr
}
t_begin "X-Sendfile does not show up in headers" && {
dbgcat curl_err
if grep -i x-sendfile $curl_err
then
die "X-Sendfile did show up!"
fi
}
# t_begin "Content-Length is set correctly in headers" && {
# expect=$(wc -c < random_blob)
# grep "^< Content-Length: $expect" $curl_err
# }
t_done
|
debug log:
solving 7ca450a ...
found 7ca450a in https://yhbt.net/rainbows-public/CAA2_N1ujCb8Yt4FGJNaTN0FdSk6g_iqL5N747Vcxt5etp9RnMw@mail.gmail.com/
found 5a9fdcd in https://yhbt.net/rainbows.git/
preparing index
index prepared:
100755 5a9fdcd17fa826387a308348c34168e37cea6d2d t/t9001-sendfile-to-path.sh
applying [1/1] https://yhbt.net/rainbows-public/CAA2_N1ujCb8Yt4FGJNaTN0FdSk6g_iqL5N747Vcxt5etp9RnMw@mail.gmail.com/
diff --git a/t/t9001-sendfile-to-path.sh b/t/t9001-sendfile-to-path.sh
index 5a9fdcd..7ca450a 100755
Checking patch t/t9001-sendfile-to-path.sh...
Applied patch t/t9001-sendfile-to-path.sh cleanly.
index at:
100755 7ca450a9a183f6d4050d7b7d97b1db969b6f03c9 t/t9001-sendfile-to-path.sh
(*) Git path names are given by the tree(s) the blob belongs to.
Blobs themselves have no identifier aside from the hash of its contents.^
Code repositories for project(s) associated with this public inbox
https://yhbt.net/rainbows.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).