Skip to content

Commit

Permalink
pytest.param doesn't seem to work in python 3.4, so removing it ;(
Browse files Browse the repository at this point in the history
  • Loading branch information
cjacoby committed Dec 13, 2017
1 parent 94b4765 commit b387ea7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 15 deletions.
5 changes: 2 additions & 3 deletions tests/test_buffered.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,8 @@ def __unpack_stream(stream):

@pytest.mark.parametrize('items',
[['X'], ['Y'], ['X', 'Y'], ['Y', 'X'],
pytest.param([],
marks=pytest.mark.xfail(
raises=pescador.PescadorError))])
pytest.mark.xfail(
[], raises=pescador.PescadorError)])
@pytest.mark.parametrize('dimension', [1, 2, 3])
@pytest.mark.parametrize('batch_size', [1, 2, 5, 17])
@pytest.mark.parametrize('buf_size', [1, 2, 5, 17, 100])
Expand Down
20 changes: 8 additions & 12 deletions tests/test_mux.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,7 @@ def test_mux_single_infinite(mux_class):
@pytest.mark.parametrize(
'items', [
['X'], ['Y'], ['X', 'Y'], ['Y', 'X'],
pytest.param([], marks=pytest.mark.xfail(
raises=pescador.PescadorError, strict=True), id='empty')])
pytest.mark.xfail([], raises=pescador.PescadorError, strict=True)])
def test_mux_single_tuple(items, mux_class):
"Test Exhaustive streamers returning tuples."

Expand All @@ -117,11 +116,10 @@ def test_mux_single_tuple(items, mux_class):
functools.partial(pescador.mux.PoissonMux, k_active=1),
pescador.mux.ShuffledMux,
pescador.mux.RoundRobinMux,
pytest.param(pescador.mux.ChainMux,
marks=pytest.mark.xfail(
reason="ChainMux can accept an empty iterable or "
"generator, and will simply return empty.",
strict=True)),
pytest.mark.xfail(pescador.mux.ChainMux,
reason="ChainMux can accept an empty iterable or "
"generator, and will simply return empty.",
strict=True),
],
ids=["DeprecatedMux",
"PoissonMux-exhaustive",
Expand Down Expand Up @@ -184,11 +182,9 @@ class TestPoissonMux_WithReplacement:
[None,
1000,
np.random.RandomState(seed=1000),
pytest.param(
'foo',
marks=pytest.mark.xfail(
raises=pescador.PescadorError,
strict=True)),
pytest.mark.xfail(
'foo', raises=pescador.PescadorError,
strict=True),
])
def test_mux_replacement(self, mux_class, n_streams, n_samples, k_active,
rate, random_state):
Expand Down

0 comments on commit b387ea7

Please sign in to comment.