Skip to content

Commit

Permalink
Add sleep between start and test
Browse files Browse the repository at this point in the history
Give the allocator enough time to complete
  • Loading branch information
WardLT committed Mar 5, 2024
1 parent 87447a4 commit 5c0789f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions colmena/thinker/tests/test_resources.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ def test_reallocator_deadlock(rec):

# Start the ML allocator, which will pull resources from sim to ml
ml_alloc.start()
sleep(0.010) # Give enough time for allocation to finish
assert not ml_alloc.stop_event.is_set()
assert rec.available_slots("ml") == 8
assert rec.acquire("ml", 8)
Expand Down

0 comments on commit 5c0789f

Please sign in to comment.