Skip to content

Commit

Permalink
ENH rm low timeout for reusable executor as it is too slow on CI
Browse files Browse the repository at this point in the history
  • Loading branch information
tomMoral committed Feb 8, 2021
1 parent 70407e9 commit 47939a3
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
3 changes: 2 additions & 1 deletion tests/_executor_mixin.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,8 @@ def setup_method(self):
try:
self.executor = self.executor_type(
max_workers=self.worker_count, context=self.context,
initializer=initializer_event, initargs=(_test_event,))
initializer=initializer_event, initargs=(_test_event,)
)
except NotImplementedError as e:
self.skipTest(str(e))
_check_executor_started(self.executor)
Expand Down
3 changes: 2 additions & 1 deletion tests/_test_process_executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,8 @@ def _test_recursive_kill(cls, depth):
executor = cls.executor_type(
max_workers=2, context=cls.context,
initializer=_executor_mixin.initializer_event,
initargs=(_executor_mixin._test_event,))
initargs=(_executor_mixin._test_event,)
)
assert executor.submit(sleep_and_return, 0, 42).result() == 42

if depth >= 2:
Expand Down
6 changes: 2 additions & 4 deletions tests/test_reusable_executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -587,10 +587,9 @@ def _worker_rank(x):
return dict(pid=os.getpid(), name=mp.current_process().name,
rank=rank, world=world)

@pytest.mark.parametrize('timeout', [10, 0.01])
def test_workers_rank_resize(self, timeout):
def test_workers_rank_resize(self):

executor = get_reusable_executor(max_workers=2, timeout=timeout)
executor = get_reusable_executor(max_workers=2)

with warnings.catch_warnings(record=True):
# Cause all warnings to always be triggered.
Expand All @@ -609,7 +608,6 @@ def test_workers_rank_resize(self, timeout):
', '.join('{}: {}'.format(k, v)
for k, v in executor._rank_mapper.items())
)
executor.shutdown(wait=True)


class TestGetReusableExecutor(ReusableExecutorMixin):
Expand Down

0 comments on commit 47939a3

Please sign in to comment.