diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/mimetest.lua | 2 | ||||
-rw-r--r-- | test/testclnt.lua | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/test/mimetest.lua b/test/mimetest.lua index 2d5bce6..66aeaf3 100644 --- a/test/mimetest.lua +++ b/test/mimetest.lua | |||
@@ -8,7 +8,7 @@ local qptest = "qptest.bin" | |||
8 | local eqptest = "qptest.bin2" | 8 | local eqptest = "qptest.bin2" |
9 | local dqptest = "qptest.bin3" | 9 | local dqptest = "qptest.bin3" |
10 | 10 | ||
11 | local b64test = "luasocket.dylib" | 11 | local b64test = "luasocket.dll" |
12 | local eb64test = "b64test.bin" | 12 | local eb64test = "b64test.bin" |
13 | local db64test = "b64test.bin2" | 13 | local db64test = "b64test.bin2" |
14 | 14 | ||
diff --git a/test/testclnt.lua b/test/testclnt.lua index 6735113..da6b2e8 100644 --- a/test/testclnt.lua +++ b/test/testclnt.lua | |||
@@ -339,12 +339,14 @@ end | |||
339 | ------------------------------------------------------------------------ | 339 | ------------------------------------------------------------------------ |
340 | function test_selectbugs() | 340 | function test_selectbugs() |
341 | local r, s, e = socket.select(nil, nil, 0.1) | 341 | local r, s, e = socket.select(nil, nil, 0.1) |
342 | assert(type(r) == "table" and type(s) == "table" and e == "timeout") | 342 | assert(type(r) == "table" and type(s) == "table" and |
343 | (e == "timeout" or e == "error")) | ||
343 | pass("both nil: ok") | 344 | pass("both nil: ok") |
344 | local udp = socket.udp() | 345 | local udp = socket.udp() |
345 | udp:close() | 346 | udp:close() |
346 | r, s, e = socket.select({ udp }, { udp }, 0.1) | 347 | r, s, e = socket.select({ udp }, { udp }, 0.1) |
347 | assert(type(r) == "table" and type(s) == "table" and e == "timeout") | 348 | assert(type(r) == "table" and type(s) == "table" and |
349 | (e == "timeout" or e == "error")) | ||
348 | pass("closed sockets: ok") | 350 | pass("closed sockets: ok") |
349 | e = pcall(socket.select, "wrong", 1, 0.1) | 351 | e = pcall(socket.select, "wrong", 1, 0.1) |
350 | assert(e == false) | 352 | assert(e == false) |