Skip to content

Commit

Permalink
Update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
TaiSakuma committed May 22, 2024
1 parent 53decdc commit b8b3fa6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion tests/stack/async/test_imp.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
from functools import partial
from os import getenv

from hypothesis import given, settings
from hypothesis import strategies as st
from pytest import mark

from apluggy import async_stack_gen_ctxs
from tests.utils import RecordReturns, ReplayReturns
Expand All @@ -10,8 +12,9 @@
from .runner import run


@mark.skipif(getenv('GITHUB_ACTIONS') == 'true', reason='Fails on GitHub Actions')
@given(st.data())
@settings(max_examples=200, deadline=None)
@settings(max_examples=200, deadline=1000)
async def test_imp(data: st.DataObject):
n_contexts = data.draw(st.integers(min_value=0, max_value=3), label='n_contexts')
n_sends = data.draw(st.integers(min_value=0, max_value=4), label='n_sends')
Expand Down
5 changes: 4 additions & 1 deletion tests/stack/async/test_refs.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,19 @@
from functools import partial
from os import getenv

from hypothesis import given, settings
from hypothesis import strategies as st
from pytest import mark

from tests.utils import RecordReturns, ReplayReturns

from .refs import dunder_enter, exit_stack, nested_with
from .runner import run


@mark.skipif(getenv('GITHUB_ACTIONS') == 'true', reason='Fails on GitHub Actions')
@given(st.data())
@settings(max_examples=200, deadline=None)
@settings(max_examples=200, deadline=1000)
async def test_refs(data: st.DataObject):
'''Assert reference implementations run in exactly the same way.'''
n_contexts = data.draw(st.integers(min_value=0, max_value=3), label='n_contexts')
Expand Down

0 comments on commit b8b3fa6

Please sign in to comment.