Skip to main content

Easy way to match captured `pytest` output against expectations stored in files

Project description

What is this

PyPI - Version Run Tests Result

This is a pytest plugin provides a couple of fixtures to match test output against patterns stored in files. Expectations/pattern files are stored in a base directory, and additional paths are based on the test module name, test class name, and test function name:

<base-dir>/<test-module-name>/[test-class-name/]<test-function-name>[[<callspec-id>]]

Having output expectations/pattern files separate from tests helps to reduce the code of the latter and match the output more than just a few lines.

Documentation

The latest documentation could be found here.

See Also

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pytest_matcher-2.0.2.tar.gz (54.4 kB view details)

Uploaded Source

Built Distribution

pytest_matcher-2.0.2-py3-none-any.whl (20.4 kB view details)

Uploaded Python 3

File details

Details for the file pytest_matcher-2.0.2.tar.gz.

File metadata

  • Download URL: pytest_matcher-2.0.2.tar.gz
  • Upload date:
  • Size: 54.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for pytest_matcher-2.0.2.tar.gz
Algorithm Hash digest
SHA256 677f379011ee7fc631300ef1b2213db2c1a6f1adb9d77948d3c9ba948396df21
MD5 350be2f8263eb9cc8df167984fd2b5fb
BLAKE2b-256 c71e0d5df3bffc632daa8913ec97308df1d5e92cbb4f3f7f393ca67cc34e4f66

See more details on using hashes here.

File details

Details for the file pytest_matcher-2.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for pytest_matcher-2.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 d0949fb9a2c9e60014bade357827109a386973870ad0aae60255021defa08b79
MD5 a20b4ed982b4c40557b8b347d9c0552a
BLAKE2b-256 4caa5c815cdfad50a337242d552062c193f2f9e7fa79e7d819a39427e7f69d06

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page