def test_failure(self): source = """ int main(int, char**) { return 1; } """ self.assertFalse(dsl.programSucceeds(self.config, source))
def test_compile_failure(self): source = """ this does not compile """ self.assertRaises(dsl.ConfigurationCompilationError, lambda: dsl.programSucceeds(self.config, source))
def test_success(self): source = """ int main(int, char**) { return 0; } """ self.assertTrue(dsl.programSucceeds(self.config, source))