mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2024-12-30 09:48:56 +00:00
get rid of flush() calls
This commit is contained in:
parent
811c7ea434
commit
d2ea9c5158
@ -5,7 +5,7 @@ from twisted.internet.defer import inlineCallbacks, Deferred
|
||||
|
||||
from eliot import log_call
|
||||
|
||||
from autobahn.twisted.testing import create_memory_agent, MemoryReactorClockResolver
|
||||
from autobahn.twisted.testing import create_memory_agent, MemoryReactorClockResolver, create_pumper
|
||||
from autobahn.twisted.websocket import WebSocketServerProtocol
|
||||
from autobahn.twisted.websocket import WebSocketClientProtocol
|
||||
|
||||
@ -21,7 +21,12 @@ class TestStreamingLogs(unittest.TestCase):
|
||||
|
||||
def setUp(self):
|
||||
self.reactor = MemoryReactorClockResolver()
|
||||
self.agent = create_memory_agent(self.reactor, TokenAuthenticatedWebSocketServerProtocol)
|
||||
self.pumper = create_pumper()
|
||||
self.agent = create_memory_agent(self.reactor, self.pumper, TokenAuthenticatedWebSocketServerProtocol)
|
||||
return self.pumper.start()
|
||||
|
||||
def tearDown(self):
|
||||
return self.pumper.stop()
|
||||
|
||||
@inlineCallbacks
|
||||
def test_one_log(self):
|
||||
@ -44,7 +49,6 @@ class TestStreamingLogs(unittest.TestCase):
|
||||
do_a_thing()
|
||||
|
||||
proto.transport.loseConnection()
|
||||
self.agent.flush()
|
||||
yield proto.is_closed
|
||||
|
||||
self.assertEqual(len(messages), 2)
|
||||
|
Loading…
Reference in New Issue
Block a user