(self)
| 22 | |
| 23 | class ErrorsTest(DFFITest): |
| 24 | def test_errors(self): |
| 25 | FFI = self.FFI |
| 26 | |
| 27 | with self.assertRaises(Exception): |
| 28 | FFI.compile("this is invalid code") |
| 29 | |
| 30 | with self.assertRaises(Exception): |
| 31 | FFI.compile("this is invalid code again") |
| 32 | |
| 33 | FFI.compile("int foo(int a, int b) { return a+b; }") |
| 34 | |
| 35 | if __name__ == '__main__': |
| 36 | unittest.main() |