/trunk/Examples/test-suite/python/cpp_enum_runme.py
Python | 23 lines | 17 code | 6 blank | 0 comment | 4 complexity | aca2440e8a63ec4302f0634f1c8a2b1a MD5 | raw file
Possible License(s): LGPL-2.1, Cube, GPL-3.0, 0BSD, GPL-2.0
- import cpp_enum
- f = cpp_enum.Foo()
- if f.hola != f.Hello:
- print f.hola
- raise RuntimeError
- f.hola = f.Hi
- if f.hola != f.Hi:
- print f.hola
- raise RuntimeError
- f.hola = f.Hello
- if f.hola != f.Hello:
- print f.hola
- raise RuntimeError
- cpp_enum.cvar.hi = cpp_enum.Hello
- if cpp_enum.cvar.hi != cpp_enum.Hello:
- print cpp_enum.cvar.hi
- raise RuntimeError