distributed-process icon indicating copy to clipboard operation
distributed-process copied to clipboard

Windows: tests aren't operational

Open NCrashed opened this issue 9 years ago • 0 comments

Windows 7 x64 Haskell platform 2014.2.0.0 network-transport-tcp-0.4.1

Target TestQC with flag use-mock-network:

C:\dev\haskell\aerospace_game\network-transport-tcp-0.4.2>cabal test TestQC
Re-configuring with test suites enabled. If this fails, please run configure
manually.
Resolving dependencies...
Configuring network-transport-tcp-0.4.2...
Preprocessing library network-transport-tcp-0.4.2...
[1 of 4] Compiling Network.Transport.TCP.Mock.Socket ( src\Network\Transport\TCP\Mock\Socket.hs, dist\build\Network\Tr
ansport\TCP\Mock\Socket.o )
[2 of 4] Compiling Network.Transport.TCP.Mock.Socket.ByteString ( src\Network\Transport\TCP\Mock\Socket\ByteString.hs,
 dist\build\Network\Transport\TCP\Mock\Socket\ByteString.o )
[3 of 4] Compiling Network.Transport.TCP.Internal ( src\Network\Transport\TCP\Internal.hs, dist\build\Network\Transpor
t\TCP\Internal.o )

src\Network\Transport\TCP\Internal.hs:37:5:
    Module
    `Network.Transport.TCP.Mock.Socket'
    does not export
    `socketPort'

Target TestTCP isn't operational (due lack of withSocketsDo):

C:\dev\haskell\aerospace_game\network-transport-tcp-0.4.2>cabal test TestTCP
Preprocessing library network-transport-tcp-0.4.2...
[1 of 2] Compiling Network.Transport.TCP.Internal ( src\Network\Transport\TCP\Internal.hs, dist\build\Network\Transpor
t\TCP\Internal.o )
[2 of 2] Compiling Network.Transport.TCP ( src\Network\Transport\TCP.hs, dist\build\Network\Transport\TCP.o )
[1 of 2] Compiling Network.Transport.TCP.Internal ( src\Network\Transport\TCP\Internal.hs, dist\build\Network\Transpor
t\TCP\Internal.p_o )
[2 of 2] Compiling Network.Transport.TCP ( src\Network\Transport\TCP.hs, dist\build\Network\Transport\TCP.p_o )
In-place registering network-transport-tcp-0.4.2...
Preprocessing test suite 'TestTCP' for network-transport-tcp-0.4.2...
[1 of 1] Compiling Main             ( tests\TestTCP.hs, dist\build\TestTCP\TestTCP-tmp\Main.o )
Linking dist\build\TestTCP\TestTCP.exe ...
Running 1 test suites...
Test suite TestTCP: RUNNING...
Running "EarlyDisconnect": TestTCP.exe: user error (Pattern match failure in do expression at tests\TestTCP.hs:108:7-2
1)
Trace:
0       Left getAddrInfo: does not exist (error 10093)

Test suite TestTCP: FAIL
Test suite logged to: dist\test\network-transport-tcp-0.4.2-TestTCP.log
0 of 1 test suites (0 of 1 test cases) passed.

With added withSocketsDo to main function:

C:\dev\haskell\aerospace_game\network-transport-tcp-0.4.2>cabal test TestTCP
Preprocessing library network-transport-tcp-0.4.2...
In-place registering network-transport-tcp-0.4.2...
Preprocessing test suite 'TestTCP' for network-transport-tcp-0.4.2...
[1 of 1] Compiling Main             ( tests\TestTCP.hs, dist\build\TestTCP\TestTCP-tmp\Main.o )
Linking dist\build\TestTCP\TestTCP.exe ...
Running 1 test suites...
Test suite TestTCP: RUNNING...
Running "EarlyDisconnect": Running "PingPong": TestTCP.exe: getConsoleScreenBufferInfo: invalid argument (Неверный дес
криптор.)
Trace:
0       Left getConsoleScreenBufferInfo: invalid argument (Неверный дескриптор.)

Test suite TestTCP: FAIL
Test suite logged to: dist\test\network-transport-tcp-0.4.2-TestTCP.log
0 of 1 test suites (0 of 1 test cases) passed.

NCrashed avatar Jul 18 '15 21:07 NCrashed