예제 #1
0
 def test_no_mock_needed(self):
     """
     The program raises MockNotFound when the program has no mock defined
     """
     gp = GiottoProgram(model=[])
     self.assertEquals({}, gp.get_model_mock())
예제 #2
0
 def test_mock_found(self):
     """
     The program raises MockNotFound when the program has no mock defined
     """
     gp = GiottoProgram(model=[model, {'mock': True}])
     self.assertEquals({'mock': True}, gp.get_model_mock())
예제 #3
0
 def test_no_mock_found(self):
     """
     The program raises MockNotFound when the program has no mock defined
     """
     gp = GiottoProgram(model=[model])
     self.assertRaises(MockNotFound, lambda: gp.get_model_mock())