Trying to get connect-with-timeout to work. Darwin works...

This commit is contained in:
Diego Nehab 2004-01-18 00:04:20 +00:00
parent 02ef4e7daa
commit c8d58798f0
14 changed files with 232 additions and 198 deletions

View file

@ -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)

View file

@ -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))