test: Add a way to mock peers for SignalProxy-related test cases
authorManuel Nickschas <sputnick@quassel-irc.org>
Thu, 4 Oct 2018 17:03:02 +0000 (19:03 +0200)
committerManuel Nickschas <sputnick@quassel-irc.org>
Sun, 18 Nov 2018 10:06:43 +0000 (11:06 +0100)
Introduce a new mock class MockedPeer that allows for setting
expectations for dispatched Quassel protocol messages. Also provide
matchers to express such expectations in a straightforward way.

MockedPeer for now only supports SignalProxy messages; support for
authentication messages can be added later if needed. Note that
expectations can be set on the level of protocol messages, but things
like a testing a particular serialization, the use of network sockets,
or other lower-level implementation details are not supported, nor is
MockedPeer intended for such use cases (we'd expect specific tests for
specific peer types).


No differences found