Contract Testing in Action

you own this product
With Pact, PactFlow, and GitHub Actions
Look inside
Contract testing is a simple, reliable way to make sure that each service and API plays nice with other components so you can deploy independently and safely.

Large, loosely coupled systems have hundreds, even thousands, of interactions—and traditional testing can often struggle to keep up! Enter contract testing. This rapidly growing new approach checks API and service compatibility by verifying it against an agreed contract. No more unexpected integration issues, and no more breaking things in production!

In Contract Testing in Action you’ll learn:

  • The core concepts and practices of contract testing
  • Testing microservices with Pact
  • Consumer-driven and bi-directional testing
  • Building a contract testing framework
  • Converting API integration tests to contract tests

Contract Testing in Action introduces the practice of contract testing through engaging hands-on examples. You’ll learn how to introduce contract tests for multiple different types of communication, from REST APIs to event-driven architecture. By the end of this practical guide, you’ll be comfortable with advanced contract testing concepts like can-i-deploy, provider states, and webhooks. You’ll even get tips on how to introduce contract testing to your team and other business stakeholders.

about the technology

It’s difficult to test API and event-based services that can be used by many applications simultaneously through a complex network of integrations. Contract testing offers a straightforward solution. API and service compatibility are verified against agreed-upon contracts that each component in the system—and the developers that build them—can understand and respect. This transformative technique helps uncover integration issues early and adds vital transparency to any system.

about the book

Contract Testing in Action makes it easy for your team to adopt contract testing for microservices and other API-centric systems. You’ll start by learning how contract testing fits into the software development lifecycle, and then you’ll explore practical methods to integrate it with your own tech stack and practices. You’ll use leading contract testing tools—including Pact, PactFlow, and GitHub Actions—to build your own contract testing framework, set up consumer-driven contract testing for REST and GraphQL APIs, and integrate it into your CI/CD pipeline.

what's inside

  • Testing microservices with Pact
  • Consumer-driven and bi-directional contract testing
  • Building a contract testing framework
  • Converting API integration tests to contract tests

about the reader

For software developers and quality engineers who have worked with Java or JavaScript, and APIs.

about the authors

Marie Cruz is a Software Tester with over ten years of experience and also a Developer Advocate at Grafana Labs. Lewis Prescott is a Test Specialist at IBM with over nine years experience in software testing.

Shows you how to add contract testing to your testing efforts, and more importantly why you should consider it.

Bas Dijkstra, On Test Automation

You’ll feel like the authors are working with you side-by and quickly reap the benefits of contract testing.

Lisa Crispin, Lisa Crispin Consulting, LLC

Incredibly comprehensive and balanced overview. I thoroughly recommend it.

Yousaf Nabi, SmartBear

Does an exceptional job of demystifying contract testing!

Rafaela Azevedo, The Chaincademy
4.6
Out of 5.0
A graph showing this site's review totals.
Overall Rating
80%
of customers that
buy this product give
it a 4 or 5-Star rating.
“Great buy”
A game-changer for understanding contract testing.
October 17, 2024 by James W. (Birmingham, United Kingdom)
“I recently bought Contract Testing in Action, and I can confidently say it was a game-changer for me. As someone who was struggling with how to structure contract testing scripts, this book helped immensely.

The authors do an incredible job of breaking down complex concepts into digestible pieces, which is exactly what I needed when I began to learn about contract testing.

The real highlight for me was that this book helped me to overcome the issues that had stopped me from progressing with my learning.

If you're new to contract testing or just looking to improve your skills, I wholeheartedly recommend Contract Testing in Action. It’s well-written, informative, and, most importantly, it made a real difference in my understanding and execution of contract testing.”
Company Choice
They were selling the book I wanted to buy.
Product Choice
It was a topic that I was learning about. I was experiencing issues and needed a guide that was clear and concise.
Verified Buyer
“Great value”
On the edge of contract testing
June 29, 2024 by Torsten W. (DE)
“The book is on the edge of contract testing, containing a lot of useful diagrams to explain the workflow of contract testing. It show when and how to use contract testing.”
Company Choice
It was the first book I konw about contract testing.
Product Choice
I use contract testing at work
Verified Buyer
“Great buy”
May 3, 2024 by A Reviewer (IN)
“Api contract testing principles explained indetails”
Verified Buyer
“Great buy”
Great Book
April 27, 2024 by A Reviewer (US)
“The information in the book has been extremely useful to several of my projects.”
Verified Buyer
October 23, 2024 by Chantal (South-Holland, NL)
“My purchase was supposed to be a combo of a hard copy and digital copy. I never received the hard copy. So I won’t go for combos anymore only the e-books.”
Company Choice
Only place to buy this book
Product Choice
Because it is relevant for my work

choose your plan

team

monthly
annual
$49.99
$399.99
only $33.33 per month
  • five seats for your team
  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose another free product every time you renew
  • choose twelve free products per year
  • exclusive 50% discount on all purchases
  • Contract Testing in Action ebook for free
choose your plan

team

monthly
annual
$49.99
$399.99
only $33.33 per month
  • five seats for your team
  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose another free product every time you renew
  • choose twelve free products per year
  • exclusive 50% discount on all purchases
  • Contract Testing in Action ebook for free
choose your plan

team

monthly
annual
$49.99
$399.99
only $33.33 per month
  • five seats for your team
  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose another free product every time you renew
  • choose twelve free products per year
  • exclusive 50% discount on all purchases
  • Contract Testing in Action ebook for free
loading book ...