Pact is the de-facto API contract testing tool. Replace expensive and brittle end-to-end integration tests with fast, reliable and easy to debug unit tests.
Why use Pact? Contract testing with Pact lets you:
Watch our series on the problems with end-to-end integrated tests, and how contract testing can help. |
This readme provides a high-level overview of the Pact Python library. For detailed documentation, please refer to the full Pact Python documentation. For a more general overview of Pact and the rest of the ecosystem, please refer to the Pact documentation.
Documentation for the API is generated from the docstrings in the code which you can view at pact-foundation.github.io/pact-python/pact
.
- Join our community slack workspace.
- Stack Overflow is a great place to ask questions.
- Say 👋 on Twitter: @pact_up
- Join a discussion 💬 on GitHub Discussions
- Raise an issue on GitHub
The latest version of Pact Python can be installed from PyPi:
pip install pact-python
# 🚀 now write some tests!
Pact Python tries to support all versions of Python that are still supported by the Python Software Foundation. Older version of Python may work, but are not officially supported.
In order to support the broadest range of use cases, Pact Python tries to impose the least restrictions on the versions of libraries that it uses.
In order to get better statistics as to who is using Pact, we collect some anonymous telemetry. The only things we record are your type of OS, and the version information for the package. No personally identifiable information is sent as part of this request. You can disable telemetry by setting the environment variable PACT_DO_NOT_TRACK=1
:
We welcome contributions to the Pact Python library in many forms. There are many ways to help, from writing code, to providing new examples, to writing documentation, to testing the library and providing feedback. For more information, see the contributing guide.