Git Product home page Git Product logo

mirror-dump / pact-python Goto Github PK

View Code? Open in Web Editor NEW

This project forked from pact-foundation/pact-python

0.0 0.0 0.0 13.22 MB

Python version of Pact. Enables consumer driven contract testing, providing a mock service and DSL for the consumer project, and interaction playback and verification for the service provider project.

Home Page: http://pact.io

License: MIT License

Shell 0.22% Python 99.52% Makefile 0.14% Dockerfile 0.12%

pact-python's Introduction

Pact Python

Fast, easy and reliable testing for your APIs and microservices.
Package Version Python Versions Downloads
CI/CD Test Status Build Status Build Status
Meta Hatch project linting - Ruff style - Ruff types - Mypy License
Community Slack Stack Overflow Twitter
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.
  • โšก Lightning fast
  • ๐ŸŽˆ Effortless full-stack integration testing - from the front-end to the back-end
  • ๐Ÿ”Œ Supports HTTP/REST and event-driven systems
  • ๐Ÿ› ๏ธ Configurable mock server
  • ๐Ÿ˜Œ Powerful matching rules prevents brittle tests
  • ๐Ÿค Integrates with Pact Broker / PactFlow for powerful CI/CD workflows
  • ๐Ÿ”ก Supports 12+ languages

Why use Pact? Contract testing with Pact lets you:

  • โšก Test locally
  • ๐Ÿš€ Deploy faster
  • โฌ‡๏ธ Reduce the lead time for change
  • ๐Ÿ’ฐ Reduce the cost of API integration testing
  • ๐Ÿ’ฅ Prevent breaking changes
  • ๐Ÿ”Ž Understand your system usage
  • ๐Ÿ“ƒ Document your APIs for free
  • ๐Ÿ—„ Remove the need for complex data fixtures
  • ๐Ÿคทโ€โ™‚๏ธ Reduce the reliance on complex test environments

Watch our series on the problems with end-to-end integrated tests, and how contract testing can help.

Documentation

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 here. Please be aware that only the [pact.v3 module][pact.v3] is thoroughly documented at this time.

Need Help

V3 Preview

Pact Python is currently undergoing a major rewrite which will be released with the 3.0.0 version. This rewrite will replace the existing Ruby backend with a Rust backend which will provide a significant performance improvement and will allow us to support more features in the future. You can find more information about this rewrite in this tracking issue on GitHub.

You can preview the new version by using the [pact.v3 module][pact.v3]. The new version is not yet feature complete, and may be subject to changes. Having said that, we would love to get your feedback on the new version:

Installation

The latest version of Pact Python can be installed from PyPi:

pip install pact-python
# ๐Ÿš€ now write some tests!

Requirements

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.

Do Not Track

In order to get better statistics as to who is using Pact, we have an anonymous tracking event that triggers when Pact installs for the first time. The only things we track are your type of OS, and the version information for the package being installed. No personally identifiable information is sent as part of this request. You can disable tracking by setting the environment variable PACT_DO_NOT_TRACK=1:

Contributing

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.

Table of contributors

pact-python's People

Contributors

alecgerona avatar b3nnyl avatar bassdread avatar bethesque avatar dependabot[bot] avatar dhoomakethu avatar dlmiddlecote avatar elliottmurray avatar ftobia avatar hartror avatar jp-ellis avatar jslvtr avatar jstoebel avatar m-aciek avatar matthewbalvanz-wf avatar mefellows avatar mikahjc avatar mikegeeves avatar pulphix avatar pyasi avatar renovate[bot] avatar sergeyklay avatar simkev2 avatar snyk-bot avatar thatguysimon avatar tuan-pham avatar valkolovos avatar williaminfante avatar yangineer avatar you54f avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.