summaryrefslogtreecommitdiffstatshomepage
path: root/tests/float/modulo.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/float/modulo.py')
-rw-r--r--tests/float/modulo.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/float/modulo.py b/tests/float/modulo.py
new file mode 100644
index 0000000000..911268513a
--- /dev/null
+++ b/tests/float/modulo.py
@@ -0,0 +1,14 @@
+# check modulo matches python definition
+# TODO we currenty fail with this
+if False:
+ print(1.23456 % 0.7)
+ print(-1.23456 % 0.7)
+ print(1.23456 % -0.7)
+ print(-1.23456 % -0.7)
+
+ a = 1.23456
+ b = 0.7
+ print(a % b)
+ print(a % -b)
+ print(-a % b)
+ print(-a % -b)