Commit f13377de authored by Simon Giesecke's avatar Simon Giesecke

Problem: test_pub_invert_matching failing

Solution: insert some sleeps to remedy timing dependencies
parent 12c6ae22
...@@ -65,6 +65,7 @@ void test () ...@@ -65,6 +65,7 @@ void test ()
// Send a message with the first prefix // Send a message with the first prefix
send_string_expect_success (pub, PREFIX1, 0); send_string_expect_success (pub, PREFIX1, 0);
msleep (SETTLE_TIME);
// sub1 should receive it, but not sub2 // sub1 should receive it, but not sub2
recv_string_expect_success (sub1, PREFIX1, ZMQ_DONTWAIT); recv_string_expect_success (sub1, PREFIX1, ZMQ_DONTWAIT);
...@@ -73,6 +74,7 @@ void test () ...@@ -73,6 +74,7 @@ void test ()
// Send a message with the second prefix // Send a message with the second prefix
send_string_expect_success (pub, PREFIX2, 0); send_string_expect_success (pub, PREFIX2, 0);
msleep (SETTLE_TIME);
// sub2 should receive it, but not sub1 // sub2 should receive it, but not sub1
recv_string_expect_success (sub2, PREFIX2, ZMQ_DONTWAIT); recv_string_expect_success (sub2, PREFIX2, ZMQ_DONTWAIT);
...@@ -92,6 +94,7 @@ void test () ...@@ -92,6 +94,7 @@ void test ()
// Send a message with the first prefix // Send a message with the first prefix
send_string_expect_success (pub, PREFIX1, 0); send_string_expect_success (pub, PREFIX1, 0);
msleep (SETTLE_TIME);
// sub2 should receive it, but not sub1 // sub2 should receive it, but not sub1
recv_string_expect_success (sub2, PREFIX1, ZMQ_DONTWAIT); recv_string_expect_success (sub2, PREFIX1, ZMQ_DONTWAIT);
...@@ -100,6 +103,7 @@ void test () ...@@ -100,6 +103,7 @@ void test ()
// Send a message with the second prefix // Send a message with the second prefix
send_string_expect_success (pub, PREFIX2, 0); send_string_expect_success (pub, PREFIX2, 0);
msleep (SETTLE_TIME);
// sub1 should receive it, but not sub2 // sub1 should receive it, but not sub2
recv_string_expect_success (sub1, PREFIX2, ZMQ_DONTWAIT); recv_string_expect_success (sub1, PREFIX2, ZMQ_DONTWAIT);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment