diff options
author | Tim-Philipp Müller <tim@centricular.com> | 2016-10-28 18:38:01 +0100 |
---|---|---|
committer | Tim-Philipp Müller <tim@centricular.com> | 2016-10-31 12:05:25 +0000 |
commit | 75084422925ef762060e03ad8150e1670d1bf7e4 (patch) | |
tree | 7c4f29e449a8c89eba3e4d4b25503088f9920221 | |
parent | fd6beb871aadf18e2dcef4749f726114a6e6ad2d (diff) |
tests: try to avoid using the same ports in different tests
Causes problems with client multicast tests otherwise if
tests are run in parallel.
https://bugzilla.gnome.org/show_bug.cgi?id=773640
-rw-r--r-- | tests/check/gst/rtspserver.c | 2 | ||||
-rw-r--r-- | tests/check/gst/stream.c | 14 |
2 files changed, 8 insertions, 8 deletions
diff --git a/tests/check/gst/rtspserver.c b/tests/check/gst/rtspserver.c index 805b177..9a9f58f 100644 --- a/tests/check/gst/rtspserver.c +++ b/tests/check/gst/rtspserver.c @@ -168,7 +168,7 @@ start_server (gboolean set_shared_factory) /* use an address pool for multicast */ pool = gst_rtsp_address_pool_new (); gst_rtsp_address_pool_add_range (pool, - "224.3.0.0", "224.3.0.10", 5000, 5010, 16); + "224.3.0.0", "224.3.0.10", 5500, 5510, 16); gst_rtsp_address_pool_add_range (pool, GST_RTSP_ADDRESS_POOL_ANY_IPV4, GST_RTSP_ADDRESS_POOL_ANY_IPV4, 6000, 6010, 0); gst_rtsp_media_factory_set_address_pool (factory, pool); diff --git a/tests/check/gst/stream.c b/tests/check/gst/stream.c index 4a0ee78..0447acc 100644 --- a/tests/check/gst/stream.c +++ b/tests/check/gst/stream.c @@ -166,21 +166,21 @@ GST_START_TEST (test_get_multicast_address) pool = gst_rtsp_address_pool_new (); fail_unless (gst_rtsp_address_pool_add_range (pool, - "233.252.0.0", "233.252.0.0", 5000, 5001, 1)); + "233.252.0.0", "233.252.0.0", 5100, 5101, 1)); fail_unless (gst_rtsp_address_pool_add_range (pool, - "FF11:DB8::1", "FF11:DB8::1", 5002, 5003, 1)); + "FF11:DB8::1", "FF11:DB8::1", 5102, 5103, 1)); gst_rtsp_stream_set_address_pool (stream, pool); addr1 = gst_rtsp_stream_get_multicast_address (stream, G_SOCKET_FAMILY_IPV4); fail_unless (addr1 != NULL); fail_unless_equals_string (addr1->address, "233.252.0.0"); - fail_unless_equals_int (addr1->port, 5000); + fail_unless_equals_int (addr1->port, 5100); fail_unless_equals_int (addr1->n_ports, 2); addr2 = gst_rtsp_stream_get_multicast_address (stream, G_SOCKET_FAMILY_IPV4); fail_unless (addr2 != NULL); fail_unless_equals_string (addr2->address, "233.252.0.0"); - fail_unless_equals_int (addr2->port, 5000); + fail_unless_equals_int (addr2->port, 5100); fail_unless_equals_int (addr2->n_ports, 2); gst_rtsp_address_free (addr1); @@ -189,13 +189,13 @@ GST_START_TEST (test_get_multicast_address) addr1 = gst_rtsp_stream_get_multicast_address (stream, G_SOCKET_FAMILY_IPV6); fail_unless (addr1 != NULL); fail_unless (!g_ascii_strcasecmp (addr1->address, "FF11:DB8::1")); - fail_unless_equals_int (addr1->port, 5002); + fail_unless_equals_int (addr1->port, 5102); fail_unless_equals_int (addr1->n_ports, 2); addr2 = gst_rtsp_stream_get_multicast_address (stream, G_SOCKET_FAMILY_IPV6); fail_unless (addr2 != NULL); fail_unless (!g_ascii_strcasecmp (addr2->address, "FF11:DB8::1")); - fail_unless_equals_int (addr2->port, 5002); + fail_unless_equals_int (addr2->port, 5102); fail_unless_equals_int (addr2->n_ports, 2); gst_rtsp_address_free (addr1); @@ -237,7 +237,7 @@ GST_START_TEST (test_multicast_address_and_unicast_udp) pool = gst_rtsp_address_pool_new (); /* add a multicast addres to the address pool */ fail_unless (gst_rtsp_address_pool_add_range (pool, - "233.252.0.0", "233.252.0.0", 5000, 5001, 1)); + "233.252.0.0", "233.252.0.0", 5200, 5201, 1)); gst_rtsp_stream_set_address_pool (stream, pool); fail_unless (gst_rtsp_stream_join_bin (stream, bin, rtpbin, GST_STATE_NULL)); |