Contract testing
APIs are the glue that allows the integration of different applications to create a rich experience. Maintaining the reliability and consistency of integrations is crucial to the success of an API product. You can think of your API’s machine-readable definition as a contract that dictates how your API behaves. You can also use that contract to check whether the behavior changes. This is what’s called contract testing. Keep reading to learn all about it and how to put it to work.
Essentially, you can define API contract testing as a set of scripts that, when executed, test how well an API conforms to what’s written in its machine-readable definition. By performing contract tests regularly, you ensure your API’s behavior is precisely as it’s documented and expected. Knowing that the API behaves as expected increases the confidence of consumers and decreases the chances of issues occurring during an integration. Let’s look...