+# Drop a contrived route table in. This table should add a reference to our
+# local IP to an entry to ensure that the route table collector code in RMr
+# is removing 'hairpin' loops. If RMr isn't removing the references to our
+# hostname and IP address when it builds the endpoint lists, the sender will
+# send messages to itself some of the time, causing the receiver to come up
+# short when comparing messages received with expected count and thus failing.
+#
+function set_rt {
+ typeset port=4560 # port the receiver listens on by default
+
+ cat <<endKat >app_test.rt
+ newrt | start
+ mse | 0 | 0 | localhost:$port,$my_ip:43086
+ mse | 1 | 10 | localhost:$port,${my_host//.*/}:43086
+ mse | 2 | 20 | localhost:$port
+ rte | 3 | localhost:$port
+ mse | 3 | 100 | localhost:$port # special test to ensure that this does not affect previous entry
+ rte | 4 | localhost:$port
+ rte | 5 | localhost:$port
+ rte | 6 | localhost:$port
+ rte | 7 | localhost:$port
+ rte | 8 | localhost:$port
+ rte | 9 | localhost:$port
+ rte | 10 | localhost:$port
+ rte | 11 | localhost:$port
+ rte | 12 | localhost:$port
+ rte | 13 | localhost:$port
+ newrt | end
+
+head -3 app_test.rt
+
+endKat
+
+}