Contract Details

This section describes the contract details page in API Hub for Contract Testing. The contract details page displays a comprehensive breakdown of the contract (pact) and verification results between a specific consumer and provider version, along with metadata and pacticipant information.

PF_Screenshot_ContractDetails.png

Statuses

The following table describes the statuses displayed on this page:

Table 4. 

Status

Description

The pact has a successful verification published for it.

❗️

The latest verification for the pact had failed.

⚠️

No verification result has been published for the pact.



You can see the interactions based on their status using the filter controls:

PF_Screenshot_ContractFilter.png

Test Details

Scenarios

Each test scenario is broken down into:

  1. The name of the scenario.

  2. Zero or more provider states, where each provider state may have associated JSON parameters.

  3. The type of interaction (one of Synchronous/HTTPSynchronous/Messages, or Asynchronous/Messages).

  4. The request and/or response(s) portion of the test.

Each test may have zero or more errors associated with it.

HTTP Requests

For HTTP interactions, the requests and responses are shown in the HTTP Message format, similar to what you would see from a cURL command.

PF_Screenshot_HTTPRequests.png

Matching rules are hidden by default. Click the toggle to reveal the matching rule information.

Asynchronous Messages

Asynchronous messages are unidirectional and only have a "request" element:

PF_Screenshot_AsynchronousMessages.png

Matching rules are hidden by default. Click the toggle to reveal the matching rule information.

Synchronous Interactions

Synchronous messages are bidirectional and have a "request" element and one or more "response" elements:

PF_Screenshot_SynchronousInteractions.png

Matching rules are hidden by default. Click the toggle to reveal the matching rule information.

Plugin Interactions

Plugin interactions may be associated with HTTP, Asynchronous, or Synchronous Messages. The layout of the tests will depend on the interaction type being used.

Additional information about the plugin will be displayed, including:

  1. Plugin markup - the plugin-defined representation of the contract.

  2. Plugin configuration - additional JSON configuration used by the plugin.

PF_Screenshot_PluginInteractions.png

Matching rules are hidden by default. Click the toggle to reveal the matching rule information.

Binary Content

Binary content will be displayed as a hexdump. ASCII characters will attempt to be displayed in the right-hand column:

 00000000: 0001 0305 1f0a 0962 6364 6566 6768 696a  .......bcdefghij
 00000010: 6b6c 6d6e 6f70 7172 7374 7576 7778 797a  klmnopqrstuvwxyz
 00000020: 3031 3233 3435 3637 3839                 0123456789

Application Information

In the right panel, information about each application in the current integration is shown, including the version, current branch, tags, and any deployed environments. The following actions are available from these tiles:

  • Copy contract URL - Copies the URL of the latest pact (consumer) or provider contract (provider).

  • Copy stub URL - Copies the URL of the stub created from the latest pact.

PF_Screenshot_ApplicationInformation.png
PF_Screenshot_ApplicationInformation_02.png

Pact Metadata

In the right panel, any metadata from the pact file is shown.

Publication date: