summary refs log tree commit diff stats
path: root/tests/run
diff options
context:
space:
mode:
authorSimon Hafner <hafnersimon@gmail.com>2012-09-08 15:15:28 -0500
committerSimon Hafner <hafnersimon@gmail.com>2012-09-08 15:15:28 -0500
commit1852c0548c23974e1d5f34f2e9d49ff63e7bc267 (patch)
tree04865e70f8b81b36160a304f73c98025b51b7cb3 /tests/run
parente9bbc7235dc017a97fdc831efdaacb5325984d18 (diff)
downloadNim-1852c0548c23974e1d5f34f2e9d49ff63e7bc267.tar.gz
hash() for floats
Diffstat (limited to 'tests/run')
-rw-r--r--tests/run/thashes.nim7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/run/thashes.nim b/tests/run/thashes.nim
new file mode 100644
index 000000000..2b418c4cd
--- /dev/null
+++ b/tests/run/thashes.nim
@@ -0,0 +1,7 @@
+import unittest
+import hashes
+
+suite "hashes":
+  suite "hashing":
+    test "0.0 and -0.0 should have the same hash value":
+      check hash(0.0) == hash(-0.0)
\ No newline at end of file