'Test that forbid_codegen() prevents code generation using the @jit
decorator.'

def test_forbid_codegen(self):

    def f():
        return 1
    with forbid_codegen():
        with self.assertRaises(RuntimeError) as raises:
            cfunc = jit(nopython=True)(f)
            cfunc()
    self.assertIn('codegen    forbidden    by    test    case', str(raises.exception))
