compyre is a tool designed to facilitate container unpacking and elementwise equality comparisons for arbitrary objects, leveraging their native comparison functionality. It is aimed at situations where users need to test potentially nested containers of values against a reference, especially when dealing with types that have their own comparison logic beyond Python's built-in types. The tool provides convenient default behaviors but remains fully configurable to accommodate various testing needs.
ndarray—can be cumbersome using standard test frameworks. While frameworks like pytest offer detailed failure reporting for built-in types, compyre addresses the gap for other common types and custom objects. It helps users avoid the need to manually loop over elements or write out individual assertions, thereby streamlining the testing process and making it easier to identify which element caused a test failure.
compyre is particularly useful for developers and testers who work with Python and encounter the challenge of asserting equality in complex data structures. It offers a configurable approach, allowing users to adapt its behavior to their specific requirements. The tool is delivered as a Python library, as indicated by its documentation and references to Python-specific types and frameworks.
The documentation credits Philip Meier as the author.
In the Testing & QA space, compyre takes a focused approach. It focuses on simplifying deep equality testing of nested containers and custom objects in Python. compyre is an open-source project aimed at python developers and testers. The project is open source (BSD-3-Clause). It runs on the command line and API, and it can be self-hosted.
compyre first shipped in 2025. The project is developed in the open on GitHub with 4 commits in the last 90 days. Among its 4 catalogued features are container unpacking, elementwise comparison, and customizable.
Latest indexed changes and source events
Other apps tracked under the same category.