summaryrefslogtreecommitdiff
path: root/Examples/test-suite/python/typename_runme.py
blob: aac936fde1514a11304ed2c199cbb68f3398fa93 (plain)
1
2
3
4
5
6
7
8
9
10
11
import typename
import types
f = typename.Foo()
b = typename.Bar()

x = typename.twoFoo(f)
if not isinstance(x, types.FloatType):
    raise RuntimeError, "Wrong return type (FloatType) !"
y = typename.twoBar(b)
if not isinstance(y, types.IntType):
    raise RuntimeError, "Wrong return type (IntType)!"