@@ -56,7 +56,7 @@ def test_pub_sub_combination(priority, reliability, congestion_control, express,
5656 handler_type = handler_type ,
5757 capacity = handler_capacity ,
5858 ),
59- vpn_ip = "172.0.0.1 " ,
59+ vpn_ip = "localhost " ,
6060 vpn_port = 7447 ,
6161 same_node = True ,
6262 ),
@@ -129,19 +129,19 @@ def test_pub_sub_combination(priority, reliability, congestion_control, express,
129129 }
130130 )
131131
132- # Start subscriber
133- subscriber_proc = subprocess .Popen (
134- [sys .executable , str (subscriber_path )], stdout = subprocess .PIPE , stderr = subprocess .PIPE , env = subscriber_env
135- )
136-
137- time .sleep (1 ) # Let subscriber boot up
138132
139133 # Start publisher (non-blocking)
140134 publisher_proc = subprocess .Popen (
141135 [sys .executable , str (publisher_path )], stdout = subprocess .PIPE , stderr = subprocess .PIPE , env = publisher_env
142136 )
143137
144138 time .sleep (1 ) # Let publisher publish + subscriber receive
139+ # Start subscriber
140+ subscriber_proc = subprocess .Popen (
141+ [sys .executable , str (subscriber_path )], stdout = subprocess .PIPE , stderr = subprocess .PIPE , env = subscriber_env
142+ )
143+
144+ time .sleep (1 ) # Let subscriber boot up
145145
146146 # Kill publisher
147147 publisher_proc .terminate ()
@@ -189,7 +189,7 @@ def test_defaults_only():
189189 topic_key = "my_topic_key" ,
190190 protocol = "zenoh" ,
191191 message_type = "make87_messages.text.text_plain.PlainText" ,
192- vpn_ip = "127.0.0.1 " ,
192+ vpn_ip = "localhost " ,
193193 vpn_port = 7447 ,
194194 same_node = True ,
195195 ),
@@ -258,24 +258,24 @@ def test_defaults_only():
258258 }
259259 )
260260
261- # Start subscriber
262- subscriber_proc = subprocess .Popen (
263- [sys .executable , str (subscriber_path )], stdout = subprocess .PIPE , stderr = subprocess .PIPE , env = subscriber_env
264- )
265-
266- time .sleep (1 ) # Let subscriber boot up
267261
268262 # Start publisher (non-blocking)
269263 publisher_proc = subprocess .Popen (
270264 [sys .executable , str (publisher_path )], stdout = subprocess .PIPE , stderr = subprocess .PIPE , env = publisher_env
271265 )
272266
273267 time .sleep (1 ) # Let publisher publish + subscriber receive
268+ # Start subscriber
269+ subscriber_proc = subprocess .Popen (
270+ [sys .executable , str (subscriber_path )], stdout = subprocess .PIPE , stderr = subprocess .PIPE , env = subscriber_env
271+ )
272+
273+ time .sleep (1 ) # Let subscriber boot up
274274
275275 # Kill publisher
276276 publisher_proc .terminate ()
277277 try :
278- publisher_proc .communicate (timeout = 5 )
278+ pub_stdout , pub_stderr = publisher_proc .communicate (timeout = 5 )
279279 except subprocess .TimeoutExpired :
280280 publisher_proc .kill ()
281281 publisher_proc .communicate ()
0 commit comments