-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
https://github.com/chainreactionmfg/cara/blob/master/tests/cara_pseud_test.py
To reduce flakiness, I took the mocking route and mocked out ZMQStream and ZMQContext. The downside was that I had to implement the ROUTER behavior in the mocked ZMQStream, but now I don't even open a port to test my code and so I can run it a hundred times (in parallel) without any failures. Of course, 100 parallel py.test instances take 40 seconds to return, but none fail now when at least 20% failed before.
Another benefit is I can check the packets that go by for the correct sender, receiver, and data. If you're interested, I can look into putting the fixture into pseud or into a separate shared project like pytest-zmq?
Metadata
Metadata
Assignees
Labels
No labels