示例#1
0
 def test_get_method(self):
     config = {'phone.method': 'mock'}
     entry_points = {'mock': MockPhoneService}
     phone = PhoneService.get(config, entry_points)
     assert_true(isinstance(phone, MockPhoneService))
 def test_get_method(self):
     config = {'phone.method': 'mock'}
     entry_points = {'mock': MockPhoneService}
     phone = PhoneService.get(config, entry_points)
     assert_true(isinstance(phone, MockPhoneService))
示例#3
0
 def test_get_default(self):
     config = {}
     entry_points = None
     phone = PhoneService.get(config, entry_points)
     assert_true(isinstance(phone, PhoneService))
 def test_get_default(self):
     config = {}
     entry_points = None
     phone = PhoneService.get(config, entry_points)
     assert_true(isinstance(phone, PhoneService))