Skip to content

Commit

Permalink
remove deadline for cpu bound tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Sune Debel committed Aug 19, 2020
1 parent eafcef7 commit 4358386
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/test_effect.py
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@ def test_memoize(self):
assert double_e.run(None) == 'result'
assert state.value == ('modify was called', )

@settings(deadline=None)
@given(effects(), effects())
def test_and_then_cpu_bound(self, e1, e2):
e1.and_then(effect.cpu_bound(lambda _: e2)).run(None) == e2.run(None)
Expand All @@ -203,6 +204,7 @@ def test_recover_io_bound(self, e):
effect.error('').recover(effect.io_bound(lambda _: e)
).run(None) == e.run(None)

@settings(deadline=None)
@given(effects(), anything())
def test_map_cpu_bound(self, e, value):
e.map(effect.cpu_bound(lambda _: value)).run(None) == value
Expand All @@ -222,6 +224,7 @@ def test_combine_io_bound(self, e1, e2):
effect.combine(e1, e2)(effect.io_bound(lambda v1, v2: (v1, v2))
).run(None) == (e1.run(None), e2.run(None))

@settings(deadline=None)
@given(effects(), effects())
def test_lift_cpu_bound(self, e1, e2):
effect.lift(effect.cpu_bound(lambda v1, v2: (v1, v2))
Expand All @@ -232,6 +235,7 @@ def test_lift_io_bound(self, e1, e2):
effect.lift(effect.io_bound(lambda v1, v2: (v1, v2))
)(e1, e2).run(None) == (e1.run(None), e2.run(None))

@settings(deadline=None)
@given(unaries(rights()))
def test_from_callable_cpu_bound(self, f):
assert effect.from_callable(effect.cpu_bound(f)
Expand Down

0 comments on commit 4358386

Please sign in to comment.