python-pytest-cases

Separate test code from test cases in pytest.

BSD-3-CLAUSE License

Downloads
658.7K
Stars
344
Committers
14

Bot releases are visible (Hide)

python-pytest-cases - 1.15.0 - better `parametrize_plus` and smaller dependencies

Published by smarie over 4 years ago

  • Better support for pytest.param in parametrize_plus and also in fixture_union and fixture_param[s]. Improved corresponding ids. Fixed #79 and #86

  • New @ignore_unused decorator to protect a fixture function from the "NOT_USED" case happening when the fixture is used in a fixture union.

  • Removed six, wrapt and enum34 dependencies

  • (Internal) submodules reorganization for readability

  • (Internal) suppressed a lot of code quality warnings

See documentation page for details.

python-pytest-cases - 1.14.0 - bugfixes and hook feature

Published by smarie over 4 years ago

  • Fixed ids precedence order when using pytest.mark.parametrize in a fixture_plus. Fixed #87

  • Fixed issue with fixture_union when using the same fixture twice in it. Fixes #85

  • Added the possibility to pass a hook function in all API where fixtures are created behind the scenes, so as to ease debugging and/or save fixtures (with stored_fixture from pytest harvest). Fixes #83

  • Fixture closures now support reordering when no unions are present. This suppressed the annoying warning "WARNING the new order is not taken into account !!" when it was not relevant. Fixes #81

See documentation page for details.

python-pytest-cases - 1.13.1 - packaging improvements

Published by smarie over 4 years ago

  • packaging improvements: set the "universal wheel" flag to 1, and cleaned up the setup.py. In particular removed dependency to six for setup and added py.typed file. Fixes #78

See documentation page for details.

python-pytest-cases - 1.13.0 - `@cases_generator` default `names`

Published by smarie over 4 years ago

@cases_generator now has a default value for the names template, based on the parameters. Fixes #77.

See documentation page for details.

python-pytest-cases - 1.12.4 - Bugfix

Published by smarie over 4 years ago

Fixed ValueError when a product of unions was used on a test node, for example when two parametrize_plus using fixture_refs were used on the same fixture or test function. Fixed #76

See documentation page for details.

python-pytest-cases - 1.12.3 - Improved error messages

Published by smarie over 4 years ago

Improved error message when something that is not a fixture is used in unpack_fixture or fixture_union. Fixed #75

See documentation page for details.

python-pytest-cases - 1.12.2 - Warning fix

Published by smarie over 4 years ago

Fixed deprecation warning #74

See documentation page for details.

python-pytest-cases - 1.12.1 - Bugfixes

Published by smarie over 4 years ago

  • Now using module name and not file path to detect symbols in cases files that are imported from elsewhere and not created locally. Indeed that was causing problems on some ^platforms where a .pyc cache file is created. Fixes #72

  • Fixed PluginValidationError when pytest_fixture_plus or pytest_parametrize_plus were used in a conftest.py file. Fixes #71. According to discussion in pytest#6475, pytest_fixture_plus and pytest_parametrize_plus are now renamed to fixture_plus and parametrize_plus in order for pytest (pluggy) not to think they are hooks. Old aliases will stay around for a few versions, with a deprecation warning.

See documentation page for details.

python-pytest-cases - 1.12.0 - better test ids for parametrized tests with fixture refs + bugfix

Published by smarie almost 5 years ago

  • Improved test ids for the cases where fixture_ref is used in the parameters list in @pytest_parametrize_plus. Fixed #69. Thanks last-partizan for the suggestion !

  • Fixed TypeError: got an unexpected keyword argument 'indirect' with pytest 5+. Fixed #70.

See documentation page for details.

python-pytest-cases - 1.11.9 - bugfix

Published by smarie almost 5 years ago

FixtureClosureNode is now able to properly handle ignore_args, and now supports that plugins append fixtures to the closure, such as pytest-asyncio. Added corresponding tests. Fixes #68

See documentation page for details.

python-pytest-cases - 1.11.8 - bugfix

Published by smarie almost 5 years ago

Fixed KeyError issue happening when a fixture is not found. Now users will see the "normal" error message from pytest ("fixture <name> not found"). Fixed #67.

See documentation page for details.

python-pytest-cases - 1.11.7 - bugfix

Published by smarie almost 5 years ago

Fixed ValueError issue happening with indirectly parametrized fixtures. Fixed #64.

See documentation page for details.

python-pytest-cases - 1.11.6 - pyproject.toml

Published by smarie almost 5 years ago

raddessi added a pyproject.toml - thanks! Fixed #65.

See documentation page for details.

python-pytest-cases - 1.11.5 - bugfix

Published by smarie almost 5 years ago

pytest_parametrize_plus was not working correctly with test classes, leading to fixture 'self' not found. Fixed #63.

See documentation page for details.

python-pytest-cases - 1.11.4 - python 2 bugfix

Published by smarie about 5 years ago

Fixed issue happening with @pytest.mark.parametrize with python 2. Fixed #62.

See documentation page for details.

python-pytest-cases - 1.11.3 - minor improvements

Published by smarie about 5 years ago

Better error message when users use THIS_MODULE in cases= instead of module=.

Added __version__ package-level attribute.

See documentation page for details.

python-pytest-cases - 1.11.2 - Increased tolerance to other plugins + bugfix

Published by smarie about 5 years ago

Now when other plugins try to manipulate the fixture closure, warning messages are emitted but no error is raised. Fixed #55.

Also fixed issue #58 happening with doctest.

See documentation page for details.

python-pytest-cases - 1.11.1 - Added `six` dependency explicitly

Published by smarie about 5 years ago

It was missing from setup.py.

See documentation page for details.

python-pytest-cases - 1.11.0 - `fixture_ref` can now be used inside tuples, leading to cross-products

Published by smarie about 5 years ago

Fixes #47.

See documentation page for details.

python-pytest-cases - 1.10.1 - Bugfix

Published by smarie over 5 years ago

Fixed #52.

See documentation page for details.

Package Rankings
Top 2.23% on Pypi.org
Top 29.85% on Conda-forge.org
Badges
Extracted from project README
Python versions Build Status Tests Status Coverage Status codecov Flake8 Status Documentation PyPI Downloads Downloads per week GitHub stars DOI