Add tests for swarm, and debug

Fix `swarm_pair_factory`
This commit is contained in:
mhchia
2019-09-15 20:44:48 +08:00
parent 276ac4d8ab
commit 0356380996
3 changed files with 56 additions and 1 deletions

View File

@ -112,7 +112,7 @@ class PubsubFactory(factory.Factory):
async def swarm_pair_factory(is_secure: bool) -> Tuple[Swarm, Swarm]:
swarms = await ListeningSwarmFactory.create_batch_and_listen(2)
swarms = await ListeningSwarmFactory.create_batch_and_listen(is_secure, 2)
await connect_swarm(swarms[0], swarms[1])
return swarms[0], swarms[1]