diff options
author | antirez <antirez@gmail.com> | 2011-01-09 16:49:52 +0100 |
---|---|---|
committer | antirez <antirez@gmail.com> | 2011-01-09 16:49:52 +0100 |
commit | 5e1d2d30f7b96c0aa808f8c6f9b267880c6097ca (patch) | |
tree | 63e3060742649415ae8e4872c871c47bb12953f2 /tests/support/tmpfile.tcl | |
parent | 67a1810b324c9f140891d4aa5b80133b66cf9a70 (diff) | |
download | redis-5e1d2d30f7b96c0aa808f8c6f9b267880c6097ca.tar.gz |
initial fix of the test suite to run both in in-memory and diskstore mode
Diffstat (limited to 'tests/support/tmpfile.tcl')
-rw-r--r-- | tests/support/tmpfile.tcl | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/support/tmpfile.tcl b/tests/support/tmpfile.tcl index 809f58730..287b09317 100644 --- a/tests/support/tmpfile.tcl +++ b/tests/support/tmpfile.tcl @@ -4,7 +4,13 @@ file mkdir $::tmproot # returns a dirname unique to this process to write to proc tmpdir {basename} { - set dir [file join $::tmproot $basename.[pid].[incr ::tmpcounter]] + if {$::diskstore} { + # For diskstore we want to use the same dir again and again + # otherwise everything is too slow. + set dir [file join $::tmproot $basename.diskstore] + } else { + set dir [file join $::tmproot $basename.[pid].[incr ::tmpcounter]] + } file mkdir $dir set _ $dir } |