예제 #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))
예제 #2
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))
예제 #3
0
 def test_get_default(self):
     config = {}
     entry_points = None
     phone = PhoneService.get(config, entry_points)
     assert_true(isinstance(phone, PhoneService))
예제 #4
0
 def test_get_default(self):
     config = {}
     entry_points = None
     phone = PhoneService.get(config, entry_points)
     assert_true(isinstance(phone, PhoneService))