Skip to content

Allow contract verification tests to have no contracts available #1298

@JamesBurnsCanva

Description

@JamesBurnsCanva

Note: This issue is written from the perspective of consuming the Java libraries.

Currently when a contract verification test has no contract available, it throws a ContractCaseConfigurationError, with contractCaseErrorCode = "UNDOCUMENTED".
This means that, short of parsing the error message, you cannot determine if a contract verification test has no contracts.

I believe contracts should be evolved on the following principles:

  • a provider / verification and a consumer / definition should not be modified in the same PR
  • a contract should not be added merged if there is nothing to verify it

Following from these principles, this means that a provider must have its contract verification test merged before any consumers create contract definition tests.
In this case, at the time of the verification test first being merged, we expect there to be no contracts defined against it.
Given that, we should support verification tests which have no contracts available.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions