Skip to content

Commit 5387cd1

Browse files
committed
update readme
1 parent 5fd987d commit 5387cd1

File tree

4 files changed

+84
-42
lines changed

4 files changed

+84
-42
lines changed

README.rst

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,14 @@ Usage
1616
.. code-block:: python
1717
1818
import pytest
19+
from pytest_lazyfixture import lazy_fixture
1920
2021
@pytest.fixture(params=[1, 2])
2122
def one(request):
2223
return request.param
2324
2425
@pytest.mark.parametrize('arg1,arg2', [
25-
('val1', pytest.lazy_fixture('one')),
26+
('val1', lazy_fixture('one')),
2627
])
2728
def test_func(arg1, arg2):
2829
assert arg2 in [1, 2]
@@ -33,10 +34,11 @@ Also you can use it as a parameter in ``@pytest.fixture``:
3334
.. code-block:: python
3435
3536
import pytest
37+
from pytest_lazyfixture import lazy_fixture
3638
3739
@pytest.fixture(params=[
38-
pytest.lazy_fixture('one'),
39-
pytest.lazy_fixture('two')
40+
lazy_fixture('one'),
41+
lazy_fixture('two')
4042
])
4143
def some(request):
4244
return request.param

setup.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
[flake8]
2+
exclude = .git,.tox,build,dist,__pycache__,.pytest_cache,.cache
23
max-line-length = 120
34
ignore = F821 W503 W504

0 commit comments

Comments
 (0)