Skip to content

Commit fc7e83d

Browse files
committed
fix
1 parent 01e30d9 commit fc7e83d

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

testing/test_workermanage.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -82,11 +82,11 @@ def test_popen_makegateway_events(
8282
call = hookrecorder.popcall("pytest_xdist_setupnodes")
8383
assert len(call.specs) == 2
8484

85-
call = hookrecorder.popcall("pytest_xdist_newgateway")
86-
assert call.gateway.spec == execnet.XSpec("execmodel=main_thread_only//popen")
87-
assert call.gateway.id == "gw0"
88-
call = hookrecorder.popcall("pytest_xdist_newgateway")
89-
assert call.gateway.id == "gw1"
85+
# check expected gateways
86+
gw_calls = [hookrecorder.popcall("pytest_xdist_newgateway"),
87+
hookrecorder.popcall("pytest_xdist_newgateway")]
88+
assert {c.gateway.id for c in gw_calls} == {"gw0", "gw1"}
89+
assert {c.gateway.spec for c in gw_calls} == {execnet.XSpec("execmodel=main_thread_only//popen")}
9090
assert len(hm.group) == 2
9191
hm.teardown_nodes()
9292
assert not len(hm.group)

0 commit comments

Comments
 (0)