BSD Ports

devel/py-pytest-cases 3.6.14 DragonFly

Separate test code from test cases in pytest

System
DragonFly
Repository
DPorts
Maintainer
[email protected] (as in FreeBSD)
License
BSD3CLAUSE
Categories
devel, python
Package size
167.3 KiB, 1056.9 KiB installed

Description

Did you ever think that most of your test functions were actually the same test code, but with different data inputs and expected results/exceptions?

  • pytest-cases leverages pytest and its great @pytest.mark.parametrize decorator, so that you can separate your test cases from your test functions.
  • In addition, pytest-cases provides several useful goodies to empower pytest. In particular it improves the fixture mechanism to support "fixture unions". This is a major change in the internal pytest engine, unlocking many possibilities such as using fixture references as parameter values in a test function. See here.

pytest-cases is fully compliant with pytest-harvest so you can easily monitor the execution times and created artifacts. With it, it becomes very easy to create a complete data science benchmark, for example comparing various models on various datasets.

In the other systems

SystemPortVersion
DragonFlydevel/py-pytest-cases3.6.14
FreeBSDdevel/py-pytest-cases3.10.1
HardenedBSDdevel/py-pytest-cases3.10.1
GhostBSDdevel/py-pytest-cases3.10.1

Install

Binary package:

pkg install py311-pytest-cases

From DPorts:

cd /usr/dports/devel/py-pytest-cases && make install clean

Dependencies

Run dependencies 3

No port depends on this one.

Configuration

No options to configure.

Service scripts
none

Message after installing

===>   NOTICE:

This port is deprecated; you may wish to reconsider installing it:

Depends on expired devel/py-makefun.

It is scheduled to be removed on or after 2025-06-01.