]> git.saurik.com Git - redis.git/commitdiff
valgrind handles floating point numbers differently for some reason, so using "simple...
authorantirez <antirez@gmail.com>
Wed, 16 Nov 2011 12:30:43 +0000 (13:30 +0100)
committerantirez <antirez@gmail.com>
Wed, 16 Nov 2011 12:35:22 +0000 (13:35 +0100)
tests/unit/basic.tcl
tests/unit/type/hash.tcl

index b76c45a47d77acdfb3dd6dd4bf94c049d8ee556b..fec782ef18ba1bed68156966231b285cc51695e2 100644 (file)
@@ -213,8 +213,8 @@ start_server {tags {"basic"}} {
 
     test {INCRBYFLOAT decrement} {
         r set foo 1
-        r incrbyfloat foo -1.256
-    } {-0.256}
+        r incrbyfloat foo -1.1
+    } {-0.1}
 
     test "SETNX target key missing" {
         r del novar
index 863c51a482191dd9a4c2a6d25f425909f63557ab..2b2a684efae0cabeea6f1707f5d6d1258abb411f 100644 (file)
@@ -335,11 +335,11 @@ start_server {tags {"hash"}} {
 
     test {HINCRBYFLOAT against hash key created by hincrby itself} {
         set rv {}
-        lappend rv [r hincrbyfloat smallhash tmp 3.1]
+        lappend rv [r hincrbyfloat smallhash tmp 3.5]
         lappend rv [r hget smallhash tmp]
-        lappend rv [r hincrbyfloat bighash tmp 3.1]
+        lappend rv [r hincrbyfloat bighash tmp 3.5]
         lappend rv [r hget bighash tmp]
-    } {5.6 5.6 5.6 5.6}
+    } {6 6 6 6}
 
     test {HINCRBYFLOAT against hash key originally set with HSET} {
         r hset smallhash tmp 100