diff --git a/tests/ovsdb-idl.at b/tests/ovsdb-idl.at
index 9d28672ef..8b1cdcdf8 100644
--- a/tests/ovsdb-idl.at
+++ b/tests/ovsdb-idl.at
@@ -1,16 +1,21 @@
 AT_BANNER([OVSDB -- interface description language (IDL)])
 
 m4_divert_text([PREPARE_TESTS], [
-# ovsdb_start_idltest [REMOTE] [SCHEMA]
+# OVSDB_START_IDLTEST([REMOTE], [SCHEMA])
 #
 # Creates a database using SCHEMA (default: idltest.ovsschema) and
 # starts a database server listening on punix:socket and REMOTE (if
 # specified).
-ovsdb_start_idltest () {
-    ovsdb-tool create db ${2:-$abs_srcdir/idltest.ovsschema} || return $?
-    ovsdb-server -vconsole:warn --log-file --detach --no-chdir --pidfile --remote=punix:socket ${1:+--remote=$1} db || return $?
-    on_exit 'kill `cat ovsdb-server.pid`'
-}
+m4_define([OVSDB_START_IDLTEST],
+[
+  AT_CHECK([ovsdb-tool create db dnl
+    m4_if([$2], [], [$abs_srcdir/idltest.ovsschema], [$2])])
+  AT_CHECK([ovsdb-server -vconsole:warn --log-file --detach --no-chdir dnl
+    --pidfile --remote=punix:socket dnl
+    m4_if([$1], [], [], [--remote=$1]) db
+  ])
+  on_exit 'kill `cat ovsdb-server.pid`'
+])
 
 # ovsdb_cluster_leader [REMOTES] [DATABASE]
 #
@@ -77,7 +82,7 @@ m4_define([OVSDB_CLUSTER_START_IDLTEST],
 m4_define([OVSDB_CHECK_IDL_C],
   [AT_SETUP([$1 - C])
    AT_KEYWORDS([ovsdb server idl positive $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 idl unix:socket $3],
@@ -91,7 +96,7 @@ m4_define([OVSDB_CHECK_IDL_C],
 m4_define([OVSDB_CHECK_IDL_WRITE_CHANGED_ONLY_C],
   [AT_SETUP([$1 - write-changed-only - C])
    AT_KEYWORDS([ovsdb server idl positive $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 --write-changed-only idl unix:socket $3],
@@ -105,7 +110,7 @@ m4_define([OVSDB_CHECK_IDL_WRITE_CHANGED_ONLY_C],
 m4_define([OVSDB_CHECK_IDL_TCP_C],
   [AT_SETUP([$1 - C - tcp])
    AT_KEYWORDS([ovsdb server idl positive tcp socket $5])
-   AT_CHECK([ovsdb_start_idltest "ptcp:0:127.0.0.1"])
+   OVSDB_START_IDLTEST(["ptcp:0:127.0.0.1"])
    PARSE_LISTENING_PORT([ovsdb-server.log], [TCP_PORT])
 
    m4_if([$2], [], [],
@@ -123,7 +128,7 @@ m4_define([OVSDB_CHECK_IDL_TCP6_C],
    AT_SKIP_IF([test "$IS_WIN32" = "yes"])
    AT_SKIP_IF([test $HAVE_IPV6 = no])
    AT_KEYWORDS([ovsdb server idl positive tcp6 socket $5])
-   AT_CHECK([ovsdb_start_idltest "ptcp:0:[[::1]]"])
+   OVSDB_START_IDLTEST(["ptcp:0:[[::1]]"])
    PARSE_LISTENING_PORT([ovsdb-server.log], [TCP_PORT])
 
    m4_if([$2], [], [],
@@ -139,7 +144,7 @@ m4_define([OVSDB_CHECK_IDL_TCP6_C],
 m4_define([OVSDB_CHECK_IDL_PY],
   [AT_SETUP([$1 - Python3])
    AT_KEYWORDS([ovsdb server idl positive Python $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([$PYTHON3 $srcdir/test-ovsdb.py  -t10 idl $srcdir/idltest.ovsschema unix:socket $3],
@@ -152,7 +157,7 @@ m4_define([OVSDB_CHECK_IDL_PY],
 m4_define([OVSDB_CHECK_IDL_REGISTER_COLUMNS_PY],
   [AT_SETUP([$1 - Python3 - register_columns])
    AT_KEYWORDS([ovsdb server idl positive Python register_columns $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([$PYTHON3 $srcdir/test-ovsdb.py  -t10 idl $srcdir/idltest.ovsschema unix:socket ?simple:b,ba,i,ia,r,ra,s,sa,u,ua?simple3:name,uset,uref?simple4:name?simple6:name,weak_ref?link1:i,k,ka,l2?link2:i,l1?singleton:name $3],
@@ -166,7 +171,7 @@ m4_define([OVSDB_CHECK_IDL_REGISTER_COLUMNS_PY],
 m4_define([OVSDB_CHECK_IDL_TCP_PY],
   [AT_SETUP([$1 - Python3 - tcp])
    AT_KEYWORDS([ovsdb server idl positive Python with tcp socket $5])
-   AT_CHECK([ovsdb_start_idltest "ptcp:0:127.0.0.1"])
+   OVSDB_START_IDLTEST(["ptcp:0:127.0.0.1"])
    PARSE_LISTENING_PORT([ovsdb-server.log], [TCP_PORT])
 
    m4_if([$2], [], [],
@@ -183,7 +188,7 @@ m4_define([OVSDB_CHECK_IDL_TCP_PY],
 m4_define([OVSDB_CHECK_IDL_TCP_MULTIPLE_REMOTES_PY],
   [AT_SETUP([$1 - Python3 (multiple remotes) - tcp])
    AT_KEYWORDS([ovsdb server idl positive Python with tcp socket $5])
-   AT_CHECK([ovsdb_start_idltest "ptcp:0:127.0.0.1"])
+   OVSDB_START_IDLTEST(["ptcp:0:127.0.0.1"])
    PARSE_LISTENING_PORT([ovsdb-server.log], [TCP_PORT])
    WRONG_PORT_1=$((TCP_PORT + 101))
    WRONG_PORT_2=$((TCP_PORT + 102))
@@ -203,7 +208,7 @@ m4_define([OVSDB_CHECK_IDL_TCP6_PY],
    AT_SKIP_IF([test "$IS_WIN32" = "yes"])
    AT_SKIP_IF([test $HAVE_IPV6 = no])
    AT_KEYWORDS([ovsdb server idl positive Python with tcp6 socket $5])
-   AT_CHECK([ovsdb_start_idltest "ptcp:0:[[::1]]"])
+   OVSDB_START_IDLTEST(["ptcp:0:[[::1]]"])
    PARSE_LISTENING_PORT([ovsdb-server.log], [TCP_PORT])
    echo "TCP_PORT=$TCP_PORT"
 
@@ -221,7 +226,7 @@ m4_define([OVSDB_CHECK_IDL_TCP6_MULTIPLE_REMOTES_PY],
    AT_SKIP_IF([test "$IS_WIN32" = "yes"])
    AT_SKIP_IF([test $HAVE_IPV6 = no])
    AT_KEYWORDS([ovsdb server idl positive Python with tcp6 socket $5])
-   AT_CHECK([ovsdb_start_idltest "ptcp:0:[[::1]]"])
+   OVSDB_START_IDLTEST(["ptcp:0:[[::1]]"])
    PARSE_LISTENING_PORT([ovsdb-server.log], [TCP_PORT])
    WRONG_PORT_1=$((TCP_PORT + 101))
    WRONG_PORT_2=$((TCP_PORT + 102))
@@ -287,13 +292,13 @@ m4_define([OVSDB_CHECK_IDL_PASSIVE_TCP_PY],
   [AT_SETUP([$1 - Python3 - ptcp])
    AT_KEYWORDS([ovsdb server idl positive Python with tcp socket $5])
    # find free TCP port
-   AT_CHECK([ovsdb_start_idltest "ptcp:0:127.0.0.1"])
+   OVSDB_START_IDLTEST(["ptcp:0:127.0.0.1"])
    PARSE_LISTENING_PORT([ovsdb-server.log], [TCP_PORT])
    OVSDB_SERVER_SHUTDOWN
    rm -f db
 
    # start OVSDB server in passive mode
-   AT_CHECK([ovsdb_start_idltest "tcp:127.0.0.1:$TCP_PORT"])
+   OVSDB_START_IDLTEST(["tcp:127.0.0.1:$TCP_PORT"])
    AT_CHECK([$PYTHON3 $srcdir/test-ovsdb.py -t10 idl_passive $srcdir/idltest.ovsschema ptcp:127.0.0.1:$TCP_PORT $3],
       [0], [stdout], [ignore])
    AT_CHECK([sort stdout | uuidfilt]m4_if([$6],,, [[| $6]]),
@@ -473,7 +478,7 @@ OVSDB_CHECK_IDL([simple idl, writing via IDL with unicode],
 m4_define([OVSDB_CHECK_IDL_PY_WITH_EXPOUT],
   [AT_SETUP([$1 - Python3])
    AT_KEYWORDS([ovsdb server idl positive Python $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([$PYTHON3 $srcdir/test-ovsdb.py  -t10 idl $srcdir/idltest.ovsschema unix:socket $3],
@@ -990,7 +995,7 @@ AT_KEYWORDS([ovsdb server idl positive])
 # table link2 and column l2 have been deleted.  But the IDL still
 # expects them to be there, so this test checks that it properly
 # tolerates them being missing.
-AT_CHECK([ovsdb_start_idltest "" "$abs_srcdir/idltest2.ovsschema"])
+OVSDB_START_IDLTEST([""], ["$abs_srcdir/idltest2.ovsschema"])
 AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 idl unix:socket ['["idltest",
       {"op": "insert",
        "table": "link1",
@@ -1063,7 +1068,7 @@ AT_CLEANUP
 m4_define([OVSDB_CHECK_IDL_FETCH_COLUMNS_PY],
   [AT_SETUP([$1 - Python3 - fetch])
    AT_KEYWORDS([ovsdb server idl positive Python increment fetch $6])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([$PYTHON3 $srcdir/test-ovsdb.py  -t10 idl $srcdir/idltest.ovsschema unix:socket [$3] $4],
@@ -1107,7 +1112,7 @@ OVSDB_CHECK_IDL_FETCH_COLUMNS([simple idl, initially populated],
 m4_define([OVSDB_CHECK_IDL_WO_MONITOR_COND_PY],
   [AT_SETUP([$1 - Python3])
    AT_KEYWORDS([ovsdb server idl Python monitor $4])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    AT_CHECK([ovs-appctl -t ovsdb-server ovsdb-server/disable-monitor-cond])
    AT_CHECK([$PYTHON3 $srcdir/test-ovsdb.py  -t10 idl $srcdir/idltest.ovsschema unix:socket $2],
             [0], [stdout], [ignore])
@@ -1200,7 +1205,7 @@ OVSDB_CHECK_IDL_WO_MONITOR_COND([simple idl disable monitor-cond],
 m4_define([OVSDB_CHECK_IDL_TRACK_C],
   [AT_SETUP([$1 - C])
    AT_KEYWORDS([ovsdb server idl tracking positive $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 -c idl unix:socket $3],
@@ -1213,7 +1218,7 @@ m4_define([OVSDB_CHECK_IDL_TRACK_C],
 m4_define([OVSDB_CHECK_IDL_TRACK_WRITE_CHANGED_ONLY_C],
   [AT_SETUP([$1 - write-changed-only - C])
    AT_KEYWORDS([ovsdb server idl tracking positive $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 -c --write-changed-only idl unix:socket $3],
@@ -1716,7 +1721,7 @@ OVSDB_CHECK_IDL_TRACK([track, simple idl, initially empty, various ops],
 m4_define([OVSDB_CHECK_IDL_PARTIAL_UPDATE_MAP_COLUMN],
   [AT_SETUP([$1 - C])
    AT_KEYWORDS([ovsdb server idl partial update map column positive $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 -c idl-partial-update-map-column unix:socket $3],
@@ -1777,7 +1782,7 @@ OVSDB_CHECK_IDL_PY([partial-map update set refmap idl],
 m4_define([OVSDB_CHECK_IDL_PARTIAL_UPDATE_SET_COLUMN],
   [AT_SETUP([$1 - C])
    AT_KEYWORDS([ovsdb server idl partial update set column positive $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 -c idl-partial-update-set-column unix:socket $3],
@@ -1966,7 +1971,7 @@ OVSDB_CHECK_IDL_NOTIFY([simple idl verify notify],
 m4_define([OVSDB_CHECK_IDL_COMPOUND_INDEX_SINGLE_COLUMN_C],
   [AT_SETUP([$1 - C])
    AT_KEYWORDS([ovsdb server idl compound_index_single_column compound_index positive $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
 # Generate the data to be tested.
@@ -2113,7 +2118,7 @@ OVSDB_CHECK_IDL_COMPOUND_INDEX_SINGLE_COLUMN_C([Compound_index, single column te
 m4_define([OVSDB_CHECK_IDL_COMPOUND_INDEX_DOUBLE_COLUMN_C],
   [AT_SETUP([$1 - C])
    AT_KEYWORDS([ovsdb server idl compound_index_double_column compound_index positive $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
 # Generate the data to be tested.
@@ -2252,7 +2257,7 @@ OVSDB_CHECK_IDL_COMPOUND_INDEX_DOUBLE_COLUMN_C([Compound_index, double column te
 m4_define([OVSDB_CHECK_IDL_COMPOUND_INDEX_WITH_REF],
   [AT_SETUP([$1 - C])
    AT_KEYWORDS([ovsdb server idl compound_index compound_index_with_ref positive $5])
-   AT_CHECK([ovsdb_start_idltest])
+   OVSDB_START_IDLTEST
    m4_if([$2], [], [],
      [AT_CHECK([ovsdb-client transact unix:socket $2], [0], [ignore], [ignore])])
    AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 -c idl-compound-index-with-ref unix:socket $3],
@@ -2280,7 +2285,7 @@ m4_define([CHECK_STREAM_OPEN_BLOCK],
    AT_SKIP_IF([test "$3" = "tcp6" && test "$IS_WIN32" = "yes"])
    AT_SKIP_IF([test "$3" = "tcp6" && test "$HAVE_IPV6" = "no"])
    AT_KEYWORDS([ovsdb server stream open_block $3])
-   AT_CHECK([ovsdb_start_idltest "ptcp:0:$4"])
+   OVSDB_START_IDLTEST(["ptcp:0:$4"])
    PARSE_LISTENING_PORT([ovsdb-server.log], [TCP_PORT])
    WRONG_PORT=$(($TCP_PORT + 101))
    AT_CHECK([$2 tcp:$4:$TCP_PORT], [0], [ignore])
@@ -2468,7 +2473,7 @@ reconnect.*waiting .* seconds before reconnect)
 
 AT_SETUP([idl table and column presence check])
 AT_KEYWORDS([ovsdb server idl table column check])
-AT_CHECK([ovsdb_start_idltest "" "$abs_srcdir/idltest2.ovsschema"])
+OVSDB_START_IDLTEST([""], ["$abs_srcdir/idltest2.ovsschema"])
 
 AT_CHECK(ovsdb-tool create db2 $abs_srcdir/idltest.ovsschema)
 AT_CHECK(ovsdb-server -vconsole:warn --log-file=ovsdb-server2.log --detach dnl
@@ -2596,7 +2601,7 @@ OVSDB_CHECK_IDL_TRACK([track, insert and delete, refs to link2],
 m4_define([OVSDB_CHECK_IDL_PERS_UUID_INSERT_C],
   [AT_SETUP([$1 - C])
    AT_KEYWORDS([idl persistent uuid insert])
-   AT_CHECK([ovsdb_start_idltest "" "$abs_srcdir/idltest.ovsschema"])
+   OVSDB_START_IDLTEST([""], ["$abs_srcdir/idltest.ovsschema"])
    AT_CHECK([test-ovsdb '-vPATTERN:console:test-ovsdb|%c|%m' -vjsonrpc -t10 idl unix:socket $2],
             [0], [stdout], [stderr])
    AT_CHECK([sort stdout],
@@ -2608,7 +2613,7 @@ m4_define([OVSDB_CHECK_IDL_PERS_UUID_INSERT_C],
 m4_define([OVSDB_CHECK_IDL_PERS_UUID_INSERT_PY],
   [AT_SETUP([$1 - Python3])
    AT_KEYWORDS([idl persistent uuid insert])
-   AT_CHECK([ovsdb_start_idltest "" "$abs_srcdir/idltest.ovsschema"])
+   OVSDB_START_IDLTEST([""], ["$abs_srcdir/idltest.ovsschema"])
    AT_CHECK([$PYTHON3 $srcdir/test-ovsdb.py  -t10 idl $srcdir/idltest.ovsschema unix:socket $2],
             [0], [stdout], [stderr])
    AT_CHECK([sort stdout],
