Trying to get connect-with-timeout to work. Darwin works...
This commit is contained in:
parent
02ef4e7daa
commit
c8d58798f0
14 changed files with 232 additions and 198 deletions
|
@ -314,9 +314,10 @@ body = socket.http.get {
|
|||
check(body == index)
|
||||
|
||||
io.write("testing HEAD method: ")
|
||||
socket.http.TIMEOUT = 1
|
||||
response = socket.http.request {
|
||||
method = "HEAD",
|
||||
url = "http://www.tecgraf.puc-rio.br/~diego/"
|
||||
url = "http://www.cs.princeton.edu/~diego/"
|
||||
}
|
||||
check(response and response.headers)
|
||||
|
||||
|
|
|
@ -359,6 +359,7 @@ test_methods(socket.tcp(), {
|
|||
"getsockname",
|
||||
"setoption",
|
||||
"settimeout",
|
||||
"shutdown",
|
||||
"close",
|
||||
})
|
||||
test_methods(socket.udp(), {
|
||||
|
@ -372,6 +373,7 @@ test_methods(socket.udp(), {
|
|||
"receivefrom",
|
||||
"setoption",
|
||||
"settimeout",
|
||||
"shutdown",
|
||||
"close",
|
||||
})
|
||||
|
||||
|
@ -484,6 +486,4 @@ test_blockingtimeoutreceive(800091, 3, 2)
|
|||
test_blockingtimeoutreceive(800091, 3, 1)
|
||||
]]
|
||||
|
||||
socket.done()
|
||||
|
||||
test(string.format("done in %.2fs", socket.time() - start))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue