Esempio n. 1
0
    def test_basic_recover(self):
        def on_recover_frame(*_):
            channel.rpc.on_frame(specification.Basic.RecoverOk())

        connection = FakeConnection(on_write=on_recover_frame)
        channel = Channel(9, connection, 1)
        channel.set_state(Channel.OPEN)
        basic = Basic(channel)

        self.assertEqual(basic.recover(), {})
Esempio n. 2
0
    def test_basic_recover(self):
        def on_recover_frame(*_):
            channel.rpc.on_frame(specification.Basic.RecoverOk())

        connection = FakeConnection(on_write=on_recover_frame)
        channel = Channel(9, connection, 1)
        channel.set_state(Channel.OPEN)
        basic = Basic(channel)

        self.assertEqual(basic.recover(), {})