aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/transport/Makefile.am20
-rwxr-xr-xsrc/transport/test_delay18
-rw-r--r--src/transport/test_transport_api_slow_ats_peer1.conf7
-rw-r--r--src/transport/test_transport_api_slow_ats_peer2.conf9
4 files changed, 50 insertions, 4 deletions
diff --git a/src/transport/Makefile.am b/src/transport/Makefile.am
index 6866ea0ee..d2dcd4236 100644
--- a/src/transport/Makefile.am
+++ b/src/transport/Makefile.am
@@ -486,7 +486,8 @@ check_PROGRAMS = \
486 $(HTTP_QUOTA_TEST) \ 486 $(HTTP_QUOTA_TEST) \
487 $(HTTPS_QUOTA_TEST) \ 487 $(HTTPS_QUOTA_TEST) \
488 $(WLAN_QUOTA_TEST) \ 488 $(WLAN_QUOTA_TEST) \
489 $(BT_QUOTA_TEST) 489 $(BT_QUOTA_TEST) \
490 test_transport_api_slow_ats
490endif 491endif
491 492
492if ENABLE_TEST_RUN 493if ENABLE_TEST_RUN
@@ -555,7 +556,8 @@ TESTS = \
555 test_quota_compliance_udp \ 556 test_quota_compliance_udp \
556 $(UNIX_QUOTA_TEST) \ 557 $(UNIX_QUOTA_TEST) \
557 $(HTTP_QUOTA_TEST) \ 558 $(HTTP_QUOTA_TEST) \
558 $(HTTPS_QUOTA_TEST) 559 $(HTTPS_QUOTA_TEST) \
560 test_transport_api_slow_ats
559endif 561endif
560 562
561test_transport_testing_startstop_SOURCES = \ 563test_transport_testing_startstop_SOURCES = \
@@ -1211,10 +1213,19 @@ test_transport_api_monitor_validation_LDADD = \
1211 $(top_builddir)/src/util/libgnunetutil.la \ 1213 $(top_builddir)/src/util/libgnunetutil.la \
1212 libgnunettransporttesting.la 1214 libgnunettransporttesting.la
1213 1215
1216test_transport_api_slow_ats_SOURCES = \
1217 test_transport_api.c
1218test_transport_api_slow_ats_LDADD = \
1219 libgnunettransport.la \
1220 $(top_builddir)/src/hello/libgnunethello.la \
1221 $(top_builddir)/src/util/libgnunetutil.la \
1222 libgnunettransporttesting.la
1223
1214 1224
1215EXTRA_DIST = \ 1225EXTRA_DIST = \
1216test_plugin_hostkey \ 1226test_plugin_hostkey \
1217test_plugin_hostkey.ecc \ 1227test_plugin_hostkey.ecc \
1228test_delay \
1218template_cfg_peer1.conf\ 1229template_cfg_peer1.conf\
1219template_cfg_peer2.conf\ 1230template_cfg_peer2.conf\
1220test_plugin_transport_data.conf\ 1231test_plugin_transport_data.conf\
@@ -1340,5 +1351,6 @@ test_transport_blacklisting_cfg_blp_peer2_multiple_plugins.conf \
1340test_transport_api_http_reverse_peer1.conf \ 1351test_transport_api_http_reverse_peer1.conf \
1341test_transport_api_http_reverse_peer2.conf \ 1352test_transport_api_http_reverse_peer2.conf \
1342perf_tcp_peer1.conf \ 1353perf_tcp_peer1.conf \
1343perf_tcp_peer2.conf 1354perf_tcp_peer2.conf \
1344 1355test_transport_api_slow_ats_peer1.conf \
1356test_transport_api_slow_ats_peer2.conf
diff --git a/src/transport/test_delay b/src/transport/test_delay
new file mode 100755
index 000000000..31c7777c4
--- /dev/null
+++ b/src/transport/test_delay
@@ -0,0 +1,18 @@
1#!/bin/sh
2
3TEMP=$(getopt -o t: -- "$@")
4
5if [ $? != 0 ] ; then
6 exit 1
7fi
8
9eval set -- "$TEMP"
10
11while true ; do
12 case "$1" in
13 (-t) sleep "$2" ; shift 2 ;;
14 (--) shift ; break ;;
15 (*) echo "Error parsing getopt output" ; exit 1 ;;
16 esac
17done
18exec "$@"
diff --git a/src/transport/test_transport_api_slow_ats_peer1.conf b/src/transport/test_transport_api_slow_ats_peer1.conf
new file mode 100644
index 000000000..5d50d5375
--- /dev/null
+++ b/src/transport/test_transport_api_slow_ats_peer1.conf
@@ -0,0 +1,7 @@
1@INLINE@ template_cfg_peer1.conf
2[PATHS]
3GNUNET_TEST_HOME = /tmp/test-transport/api-slow-ats-p1/
4
5[transport]
6PLUGINS = tcp
7
diff --git a/src/transport/test_transport_api_slow_ats_peer2.conf b/src/transport/test_transport_api_slow_ats_peer2.conf
new file mode 100644
index 000000000..4895e4c4f
--- /dev/null
+++ b/src/transport/test_transport_api_slow_ats_peer2.conf
@@ -0,0 +1,9 @@
1@INLINE@ template_cfg_peer2.conf
2[PATHS]
3GNUNET_TEST_HOME = /tmp/test-transport/api-slow-ats-p2/
4
5[transport]
6PLUGINS = tcp
7
8[ats]
9PREFIX = ./test_delay -t 30 --