Пример #1
0
 def test_create_endpoint_with_tuple(self):
     ep = SendingBaseEndpoint(node=Mock(spec=NodeB))
     e = ep.create_endpoint(to_name=(sentinel.ex, sentinel.name))
     self.assertIsInstance(e.channel.connect.call_args[0][0], NameTrio)
Пример #2
0
 def test_create_endpoint_with_tuple(self):
     ep = SendingBaseEndpoint(node=Mock(spec=NodeB))
     e = ep.create_endpoint(to_name=(sentinel.ex, sentinel.name))
     self.assertIsInstance(e.channel.connect.call_args[0][0], NameTrio)
Пример #3
0
 def test_create_endpoint_calls_connect(self):
     np = NameTrio(sentinel.xp, sentinel.queue)
     ep = SendingBaseEndpoint(node=Mock(spec=NodeB), to_name=np)
     e = ep.create_endpoint()
     e.channel.connect.assert_called_once_with(np)
Пример #4
0
 def test_create_endpoint_calls_connect(self):
     np = NameTrio(sentinel.xp, sentinel.queue)
     ep = SendingBaseEndpoint(node=Mock(spec=NodeB), to_name=np)
     e = ep.create_endpoint()
     e.channel.connect.assert_called_once_with(np)