$npx skillfedfor your agent

re-assert

show where your regex match assertion failed!

Worth itPyPI TestingReleased Feb 202080.5K downloads / moMITPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — re_assert-1.1.0-py2.py3-none-any.whl
v1.1.0 · released 2020-02-25 · Python >=3.6.1 · 1 runtime deps: regex

Yes. It is a focused, well-maintained tool with no security issues, low install friction, and a permissive license. If you write regex-based tests in pytest or other frameworks, it directly improves test readability and debugging speed with minimal overhead.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.6.1 or later; regex library must be installed (handled by pip).
  • Low friction: pure Python wheel with a single runtime dependency on regex.
  • Actively maintained with a recent commit in July 2026.

License · maintenance · safety

MIT (permissive) — MIT license permits unrestricted use, modification, and distribution in both open and closed projects.

last release 2020-02-25 (2362 days) · last repo commit 2026-07-15 · 83 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 80,461 downloads/mo, #14,290 on PyPI

Verify before relying

pip install re-assert

from re_assert import Matches

# In a pytest test:
assert Matches('foo') == 'food'  # passes
assert Matches('foo') == 'fork'   # fails with clear diagnostic

# Or with assert_matches():
Matches('foo').assert_matches('food')
  • Whether regex library's 100% compatibility claim with re library extends to all edge cases in practice.
  • Performance characteristics when used with complex patterns or large volumes of assertions.
Same gist for agents: .md · .json

What it is and what it does

re-assert wraps regex pattern matching to provide readable failure diagnostics in test assertions. When a pattern fails to match, it shows the exact position in the input string where the match broke down, with visual markers pointing to the failure point. This is especially useful in pytest, where the overridden equality operator integrates directly into assertion output; for other test frameworks, the `assert_matches()` method produces similarly clear tracebacks.

Under the hood, re-assert uses the regex library (which is a drop-in replacement for Python's built-in re module) to compile and match patterns. You construct a Matches object with a pattern string or an already-compiled regex, then use it like a normal value in equality assertions or call `assert_matches()` directly. The library is designed to be lightweight and requires only the regex dependency.

Use it for

  • Write pytest tests for regex patterns with clear failure messages showing exactly where the match failed.
  • Debug regex patterns during development by seeing the precise mismatch point instead of a generic False result.
  • Test compiled regex objects from existing code without rewriting the pattern as a string.
  • Use in non-pytest test frameworks via the assert_matches() method for readable regex validation errors.
  • Validate input patterns in data pipelines where regex failures need to be quickly diagnosed.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

It is a focused, well-maintained tool with no security issues, low install friction, and a permissive license. If you write regex-based tests in pytest or other frameworks, it directly improves test readability and debugging speed with minimal overhead.

Install

re-assert on PyPI

Before you install

Low friction: pure Python wheel with a single runtime dependency on regex. Actively maintained with a recent commit in July 2026.

Requires Python 3.6.1 or later; regex library must be installed (handled by pip).

License in practice

MIT license permits unrestricted use, modification, and distribution in both open and closed projects.

Quickstart

pip install re-assert

from re_assert import Matches

# In a pytest test:
assert Matches('foo') == 'food'  # passes
assert Matches('foo') == 'fork'   # fails with clear diagnostic

# Or with assert_matches():
Matches('foo').assert_matches('food')

Verify before relying

  • Whether regex library's 100% compatibility claim with re library extends to all edge cases in practice.
  • Performance characteristics when used with complex patterns or large volumes of assertions.

Package facts

LicenseMIT permissive
Python supportSupports the current Python release >=3.6.1
Install frictionLow. Pure-Python wheel
Runtime dependencies
1 package
regex
MaintenanceActively maintained 2,362 days since the last release
Last repo commit
First released
Downloads80,461 / month, #14,290 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
License :: OSI Approved :: MIT LicenseProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.6Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8

Evidence: re_assert-1.1.0-py2.py3-none-any.whl

Tags

Capabilities
regex assertion testingpytest regex match debuggingregex pattern validationtest regex failuresregex matching assertionspattern match error messagesregex test helper
Topics
regex-testingpytest-pluginassertion-helper

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “regex assertion testing”

Give your agent the search over MCP, or paste the wish link into any chat.

More Testing packages

pluggy Worth it
PyPI · Libraries · released May 2025

Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.

Install it if you're building an extensible application or framework.

MITpure Python · 3.9+aging
1.3Bdownloads / mo
pytest Worth it
PyPI · Libraries · released Jun 2026

pytest is a testing framework that lets you write test functions using plain assert statements and automatically discovers and runs them, with detailed failure reporting.

MITpure Python · 3.10+
1.1Bdownloads / mo
virtualenv Worth it
PyPI · Libraries · released Aug 2026

virtualenv creates isolated Python environments where packages can be installed independently without affecting the system Python or other projects.

MITpure Python · 3.9+
532.9Mdownloads / mo
coverage Worth it
PyPI · Testing · released Aug 2026

Coverage.py measures which lines of Python code are executed during test runs, reporting coverage percentages and identifying untested code paths.

Install it if you want to measure test completeness or enforce coverage thresholds in your project.

permissive licensepure Python · 3.10+
335.8Mdownloads / mo
pytest-asyncio Worth it
PyPI · Testing · released May 2026

pytest-asyncio is a pytest plugin that enables writing and running async test functions using the asyncio library, allowing developers to await code directly within test cases.

Install it if you write tests for any asyncio-based code.

Apache-2.0pure Python · 3.10+
275.9Mdownloads / mo
pytest-json-ctrf Worth it
PyPI · Testing · released Jul 2026

A pytest plugin that generates test reports in Common Test Report Format (CTRF) as JSON, compatible with pytest-xdist and pytest-playwright for distributed and browser-based testing.

Install it if you need CTRF-formatted test output for CI/CD integration or cross-tool reporting.

MITpure Python · 3.8+
273.0Mdownloads / mo

See also asserts · dirty-equals · pytest-assume · pytest-regex · pytest-unordered · pytest-deepassert · ensure · delayed-assert · pytest-mypy-plugins · pytest-reraise