BSD Ports

devel/py-pytest-arraydiff 0.7.0 DragonFly

Pytest plugin to help with comparing array output from tests

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

Description

pytest-arraydiff is a py.test plugin to facilitate the generation and comparison of data arrays produced during tests, in particular in cases where the arrays are too large to conveniently hard-code them in the tests (e.g. np.testing.assert_allclose(x, [1, 2, 3])).

The basic idea is that you can write a test that generates a Numpy array (or other related objects depending on the format, e.g. pandas DataFrame). You can then either run the tests in a mode to generate reference files from the arrays, or you can run the tests in comparison mode, which will compare the results of the tests to the reference ones within some tolerance.

At the moment, the supported file formats for the reference files are: * A plain text-based format (based on Numpy loadtxt output) * The FITS format (requires astropy). With this format, tests can return either a Numpy array for a FITS HDU object. * A pandas HDF5 format using the pandas HDFStore

In the other systems

The newest version among them is 0.7.0, as upstream numbers it.

SystemPortVersionVulnerabilitiesStatusMaintainerLast update
DragonFlydevel/py-pytest-arraydiff0.7.0 newestnone known-[email protected]-
FreeBSDdevel/py-pytest-arraydiff0.7.0 newestnone known-[email protected]2026-08-07
HardenedBSDdevel/py-pytest-arraydiff0.7.0 newestno data-[email protected]-
GhostBSDdevel/py-pytest-arraydiff0.7.0 newestno data-[email protected]-

Version history 1

  1. 0.7.0

Upstream's version as each commit to the port's Makefile set it, or as this site first saw it in the system's packages; the tree's own revisions are not versions here.

Install

Binary package:

pkg install py312-pytest-arraydiff

From DPorts:

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

Dependency graph

Ports that need it on the left, what it needs to run on the right; at most 8 of each. "Dependencies" below lists them all.

Dependencies

Run dependencies 3
Required by 1