pass in api_url to agents in tests
This commit is contained in:
@@ -43,7 +43,10 @@ class TestBaseTeethAgent(unittest.TestCase):
|
||||
self.encoder = encoding.RESTJSONEncoder(
|
||||
encoding.SerializationViews.PUBLIC,
|
||||
indent=4)
|
||||
self.agent = base.BaseTeethAgent('fake_host', 'fake_port', 'TEST_MODE')
|
||||
self.agent = base.BaseTeethAgent('fake_host',
|
||||
'fake_port',
|
||||
'fake_api',
|
||||
'TEST_MODE')
|
||||
|
||||
def assertEqualEncoded(self, a, b):
|
||||
# Evidently JSONEncoder.default() can't handle None (??) so we have to
|
||||
|
||||
@@ -21,7 +21,7 @@ from teeth_agent import decom
|
||||
|
||||
class TestBaseTeethAgent(unittest.TestCase):
|
||||
def setUp(self):
|
||||
self.agent = decom.DecomAgent('fake_host', 'fake_port')
|
||||
self.agent = decom.DecomAgent('fake_host', 'fake_port', 'fake_api')
|
||||
|
||||
def test_decom_mode(self):
|
||||
self.assertEqual(self.agent.mode, 'DECOM')
|
||||
|
||||
@@ -22,7 +22,7 @@ from teeth_agent import standby
|
||||
|
||||
class TestBaseTeethAgent(unittest.TestCase):
|
||||
def setUp(self):
|
||||
self.agent = standby.StandbyAgent('fake_host', 'fake_port')
|
||||
self.agent = standby.StandbyAgent('fake_host', 'fake_port', 'fake_api')
|
||||
|
||||
def test_standby_mode(self):
|
||||
self.assertEqual(self.agent.mode, 'STANDBY')
|
||||
|
||||
Reference in New Issue
Block a user