예제 #1
0
 def test_start(self):
     c = Mock()
     agent = Agent(c)
     agent.instantiate = Mock()
     agent.agent_cls = 'foo:Agent'
     self.assertIsNotNone(agent.create(c))
     agent.instantiate.assert_called_with(agent.agent_cls, c.connection)
예제 #2
0
 def test_start(self):
     c = Mock()
     agent = Agent(c)
     agent.instantiate = Mock()
     agent.agent_cls = 'foo:Agent'
     self.assertIsNotNone(agent.create(c))
     agent.instantiate.assert_called_with(agent.agent_cls, c.connection)