X-Git-Url: https://git.saurik.com/redis.git/blobdiff_plain/6485f293827bed97a791ff6c88a8f3d92b00b1c5..a42453a5931165b87335fd2fb744ec1c3b89fe8f:/test-redis.tcl diff --git a/test-redis.tcl b/test-redis.tcl index a306ea6a..3b5900f9 100644 --- a/test-redis.tcl +++ b/test-redis.tcl @@ -191,45 +191,7 @@ proc createComplexDataset {r ops} { } proc datasetDigest r { - set keys [lsort [$r keys *]] - set digest {} - foreach k $keys { - set t [$r type $k] - switch $t { - {string} { - set aux [::sha1::sha1 -hex [$r get $k]] - } {list} { - if {[$r llen $k] == 0} { - set aux {} - } else { - set aux [::sha1::sha1 -hex [$r lrange $k 0 -1]] - } - } {set} { - if {[$r scard $k] == 0} { - set aux {} - } else { - set aux [::sha1::sha1 -hex [lsort [$r smembers $k]]] - } - } {zset} { - if {[$r zcard $k] == 0} { - set aux {} - } else { - set aux [::sha1::sha1 -hex [$r zrange $k 0 -1]] - } - } {hash} { - if {[$r hlen $k] == 0} { - set aux {} - } else { - set aux [::sha1::sha1 -hex [lsort [$r hgetall $k]]] - } - } default { - error "Type not supported: $t" - } - } - if {$aux eq {}} continue - set digest [::sha1::sha1 -hex [join [list $aux $digest $k] "\n"]] - } - return $digest + $r debug digest } proc main {} {