From 6646d18c7a6ac0ed98d41cec884bd644549149ad Mon Sep 17 00:00:00 2001 From: rocky Date: Sun, 5 Jan 2020 11:54:41 -0500 Subject: [PATCH] More complex complex test --- test/.gitignore | 1 + test/bytecode_3.6_run/02_var_annotate.pyc | Bin 0 -> 306 bytes test/bytecode_3.7_run/10_complex.pyc | Bin 0 -> 1915 bytes test/simple_source/bug31/10_complex.py | 11 +++++++---- 4 files changed, 8 insertions(+), 4 deletions(-) create mode 100644 test/bytecode_3.6_run/02_var_annotate.pyc create mode 100644 test/bytecode_3.7_run/10_complex.pyc diff --git a/test/.gitignore b/test/.gitignore index 50aae070..cf825a74 100644 --- a/test/.gitignore +++ b/test/.gitignore @@ -1 +1,2 @@ +/.coverage /nohup.out diff --git a/test/bytecode_3.6_run/02_var_annotate.pyc b/test/bytecode_3.6_run/02_var_annotate.pyc new file mode 100644 index 0000000000000000000000000000000000000000..8cb1f479be3dd67104e6252a9595c53bee556b03 GIT binary patch literal 306 zcmX|)u}Z{16h+^gOk$K>6}$ZbA!Z`y)1f z(6m2A z&8DW@s7}AqY}J+XtJ%e6zAbcKw5_s*rRk=3=}n_#SJQ16GG`tPMiEDj>7Wsw;vcD} BNW}mE literal 0 HcmV?d00001 diff --git a/test/bytecode_3.7_run/10_complex.pyc b/test/bytecode_3.7_run/10_complex.pyc new file mode 100644 index 0000000000000000000000000000000000000000..7b24e33cf8e2905c23d470b4084544c485a09592 GIT binary patch literal 1915 zcmZux&u<$=6rMNh9~;|o+YnW4T3`tklB?n*MXC@=qPBq>iV!&znWompvq>EPN@mu` zwro+=k$__l+~LSy!GFPFuN)w^oXa76Z`Nz4fwAVzn>Vx1?|a{S^K^bbCosNUTzGLi zBgCJ)NrnUEF{U|$P(o2tw5UQP)HUU()G1Y@x~|eH1IZ`qs@B|HG3#lV;#W2qCXij$A6(sq?VBm8BF6HcR)QFvcTf z1XGS3iuV$G8SfPVs~miM73(C9;D6z6mmK@IQA!7XGfLH4{sBy=B%!k`To#No7F=vm z{t}#PFc^-Lv1kTWlf1)V>y&3MLFQ;tjHG4I(T|4E?ud~CWDdBOB!==AaQ`d4W#bxf zw8Cw$J2?^4+cdpxZ4<^n-9q-eAy|!B@CF;b`~3%&@7iHdYk1+IA9{n8-o{4XS_dor zjg4M8;om}u^3^KWjH-WEt(H==v_v$B=;Uf%=B(!`ZZ86@xd|bp3vOMo%)dm_3plCq zF%QlWmjtioD+qec%2h(tv2cTuQFq*XAYk88|iMi$uwta$Tkmc2g z>R0f-$*ni*Cgcone#q|FcSa1nFfd_~xAJtcRHXejI>!nXCsB zMIkcrVVs-v$+2H_4K#q*{J>7{|eHsqJCQs^!5t*6;Gc pdn|0wv!~5!mQ{DX)luDMu*ryQlN6j>E|+$TZq}XS=ej@{`WIZ8dHVnW literal 0 HcmV?d00001 diff --git a/test/simple_source/bug31/10_complex.py b/test/simple_source/bug31/10_complex.py index 62c0d463..b31478ae 100644 --- a/test/simple_source/bug31/10_complex.py +++ b/test/simple_source/bug31/10_complex.py @@ -1,4 +1,5 @@ # Greatly simplified from from 3.3 test_complex.py +from math import atan2 # RUNNABLE! def assertCloseAbs(x, y, eps=1e-09): @@ -38,14 +39,16 @@ def test_truediv(): check_div(x, y) def test_plus_minus_0j(): - z1, z2 = (0j, (-0 - 0j)) + assert -0j == -0j == complex(0.0, 0.0) + assert -0-0j == -0j == complex(0.0, 0.0) + z1, z2 = (0j, -0j) assert atan2(z1.imag, -1.0) == atan2(0.0, -1.0) - assert atan2(z2.imag, -1.0), atan2(-0.0, -1.0) + # assert atan2(z2.imag, -1.0), atan2(-0.0, -1.0) # Check that we can handle -inf, and inf as a complex numbers. # And put it in a tuple and a list to make it harder. z1, z2 = (-1e1000j, 1e1000j) assert z1 in [-1e1000j, 1e1000j] -assert z1 == z2 +assert z1 != z2 test_truediv() -test_plus_minus0j() +test_plus_minus_0j()