diff options
Diffstat (limited to 'Examples/test-suite/python/complextest_runme.py')
-rw-r--r-- | Examples/test-suite/python/complextest_runme.py | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/Examples/test-suite/python/complextest_runme.py b/Examples/test-suite/python/complextest_runme.py index 7dd7f5a3b..5cfc7ccab 100644 --- a/Examples/test-suite/python/complextest_runme.py +++ b/Examples/test-suite/python/complextest_runme.py @@ -8,10 +8,23 @@ if complextest.Conj(a) != a.conjugate(): if complextest.Conjf(a) != a.conjugate(): raise RuntimeError, "bad complex mapping" +if complextest.Conj2(a) != a.conjugate(): + raise RuntimeError, "bad complex mapping" + +if complextest.Conjf2(a) != a.conjugate(): + raise RuntimeError, "bad complex mapping" + v = (complex(1, 2), complex(2, 3), complex(4, 3), 1) -try: - complextest.Copy_h(v) -except: - pass +if len(complextest.CopyHalf(v)) != 2: + raise RuntimeError("CopyHalf failed") + +if len(complextest.CopyHalfRef(v)) != 2: + raise RuntimeError("CopyHalfRef failed") + +p = complextest.ComplexPair() +p.z1 = complex(0, 1) +p.z2 = complex(0, -1) +if complextest.Conj(p.z2) != p.z1: + raise RuntimeError, "bad complex mapping" |