inc/common.sh changes to support the testcase:
$ bzr diff test/inc/common.sh === modified file 'test/inc/common.sh' --- test/inc/common.sh 2013-03-08 04:37:16 +0000 +++ test/inc/common.sh 2013-03-18 05:20:44 +0000 @@ -436,5 +436,20 @@ return ${PIPESTATUS[0]} }
+function open_persistent_mysql_pipe() +{ + local pipe=$(mktemp -u) + mkfifo -m 600 $pipe + eval "$1=$pipe" + (tail -f $pipe) | ${MYSQL} ${MYSQL_ARGS} & +} + +function close_persistent_mysql_pipe() +{ + local pipe=$1 + echo "exit" > $pipe + rm $pipe +} + # To avoid unbound variable error when no server have been started SRV_MYSQLD_IDS=
inc/common.sh changes to support the testcase:
$ bzr diff test/inc/common.sh common. sh'
=== modified file 'test/inc/
--- test/inc/common.sh 2013-03-08 04:37:16 +0000
+++ test/inc/common.sh 2013-03-18 05:20:44 +0000
@@ -436,5 +436,20 @@
return ${PIPESTATUS[0]}
}
+function open_persistent _mysql_ pipe() t_mysql_ pipe()
+{
+ local pipe=$(mktemp -u)
+ mkfifo -m 600 $pipe
+ eval "$1=$pipe"
+ (tail -f $pipe) | ${MYSQL} ${MYSQL_ARGS} &
+}
+
+function close_persisten
+{
+ local pipe=$1
+ echo "exit" > $pipe
+ rm $pipe
+}
+
# To avoid unbound variable error when no server have been started
SRV_MYSQLD_IDS=