Pytest-cases

Latest version: v3.8.6

Safety actively analyzes 685838 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 6 of 20

3.2.1

- Fixed `fixture 'self' not found` issue when `fixture` was used to decorate a class method not explicitly depending on `request`. Fixed [182](https://github.com/smarie/python-pytest-cases/issues/182)

3.2.0

- New: from version `3.2` on, if `auto_refs=True` (default), `parametrize` will automatically detect fixture symbols in the list of argvalues, and will create `fixture_ref`s automatically around them so that you don't need to. Fixes [177](https://github.com/smarie/python-pytest-cases/issues/177)

- Fixed ordering issue happening on linux targets when several `parametrize` are used to decorate the same function. Fixes [180](https://github.com/smarie/python-pytest-cases/issues/180)

3.1.2

- Now appending fixtures to the closure once it has been built is supported. This fixes an issue with `pytest-asyncio`. Fixes [176](https://github.com/smarie/python-pytest-cases/issues/176)

- Fixed issue when `parametrize_with_cases` was used on case functions themselves (nesting/recursion). This was due to a lack of support of the `place_as` magic pytest attribute. Fixes [179](https://github.com/smarie/python-pytest-cases/issues/179)

- Added a warning concerning usage of indirect in parametrize when fixture references are present. See [150](https://github.com/smarie/python-pytest-cases/issues/150)

3.1.1

- Fixed issue with Empty id marker leaking to test ids. Fixed [171](https://github.com/smarie/python-pytest-cases/issues/171)

3.1.0

- `parametrize_with_cases` now by default (`cases=AUTO`) looks for both file naming patterns `test_<name>_cases.py` and `cases_<name>.py`. Removed the `AUTO2` constant. Fixed [140](https://github.com/smarie/python-pytest-cases/issues/140)

- Nested classes containing case functions are now officially supported (they were, but undocumented). Fixed [160](https://github.com/smarie/python-pytest-cases/issues/160)

- Case functions that are `staticmethod` and `classmethod` are now supported as well. Fixes [168](https://github.com/smarie/python-pytest-cases/issues/168)

3.0.0

- Major refactoring of the way ids and marks are generated and customized in `fixture_union`, `parametrize` and `parametrize_with_cases`. Now `idstyle` has a consistent behaviour across the board, `ids` and `idstyle` can work together correctly, `parametrize_with_cases` and `parametrize` have much better default values for ids, and many others. See [documentation](./index.md) for details. Fixed [154](https://github.com/smarie/python-pytest-cases/issues/154)

- New public API to manipulate information about a case function: `copy_case_info`, `set_case_id`, `get_case_id`, `get_case_marks`, `get_case_tags`, `matches_tag_query`, `is_case_class`, `is_case_function`. See [API reference](./api_reference.md).

- Fixed default behaviour of `idgen` in `parametrize`: it only defaults to `AUTO` when no `fixture_ref` are used in the argvalues.

Page 6 of 20

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.