gameServer/stresstest2.hs
changeset 2352 7eaf82cf0890
parent 1804 4e78ad846fb6
child 2948 3f21a9dc93d0
equal deleted inserted replaced
2351:a4a17b8df591 2352:7eaf82cf0890
    12 
    12 
    13 #if !defined(mingw32_HOST_OS)
    13 #if !defined(mingw32_HOST_OS)
    14 import System.Posix
    14 import System.Posix
    15 #endif
    15 #endif
    16 
    16 
    17 testing = Control.Exception.handle (\e -> putStrLn $ show e) $ do
    17 testing = Control.Exception.handle print $ do
    18 	delay <- randomRIO (100::Int, 300)
    18 	delay <- randomRIO (100::Int, 300)
    19 	threadDelay delay
    19 	threadDelay delay
    20 	sock <- connectTo "127.0.0.1" (PortNumber 46631)
    20 	sock <- connectTo "127.0.0.1" (PortNumber 46631)
    21 	hClose sock
    21 	hClose sock
    22 
    22