summaryrefslogtreecommitdiff
path: root/tests/instances.tcl
diff options
context:
space:
mode:
Diffstat (limited to 'tests/instances.tcl')
-rw-r--r--tests/instances.tcl8
1 files changed, 6 insertions, 2 deletions
diff --git a/tests/instances.tcl b/tests/instances.tcl
index 358c2affc..26d0737c6 100644
--- a/tests/instances.tcl
+++ b/tests/instances.tcl
@@ -74,11 +74,13 @@ proc spawn_instance {type base_port count {conf {}}} {
}
# Push the instance into the right list
+ set link [redis 127.0.0.1 $port]
+ $link reconnect 1
lappend ::${type}_instances [list \
pid $pid \
host 127.0.0.1 \
port $port \
- link [redis 127.0.0.1 $port] \
+ link $link \
]
}
}
@@ -398,6 +400,8 @@ proc restart_instance {type id} {
}
# Connect with it with a fresh link
- set_instance_attrib $type $id link [redis 127.0.0.1 $port]
+ set link [redis 127.0.0.1 $port]
+ $link reconnect 1
+ set_instance_attrib $type $id link $link
}