@unittest.skipIf(test_support.is_jython, "FIXME: not working in Jython")
    def test_func_code(self):
        num_one, num_two = 7, 8
        def a(): pass
        def b(): return 12
        def c(): return num_one
        def d(): return num_two
        def e(): return num_one, num_two
        for func in [a, b, c, d, e]:
            self.assertEqual(type(func.func_code), types.CodeType)
        self.assertEqual(c(), 7)
        self.assertEqual(d(), 8)
        d.func_code = c.func_code
        self.assertEqual(c.func_code, d.func_code)
        self.assertEqual(c(), 7)
        # self.assertEqual(d(), 7)
        try:
            b.func_code = c.func_code
        except ValueError:
            pass
        else:
            self.fail("func_code with different numbers of free vars should "
                      "not be possible")
        try:
            e.func_code = d.func_code
        except __HOLE__:
            pass
        else:
            self.fail("func_code with different numbers of free vars should "
                      "not be possible")
dataset/ETHPy150Open azoft-dev-team/imagrium/env/Lib/test/test_funcattrs.py/FunctionPropertiesTest.test_func_code