Our great sponsors
-
Pact JVM
JVM 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.
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
-
testcontainers-go
Testcontainers for Go is a Go package that makes it simple to create and clean up container-based dependencies for automated integration/smoke tests. The clean, easy-to-use API enables developers to programmatically define containers that should be run as part of a test and clean up those resources when the test is done.
If you want to make sure the server implements a certain contract like there's an handler responding to a GET request to /API/what/ever I'd rather use something else. To be completely honest this is a topic I'm currently also searching for a really good solution but what I found so far (and looks promising) is https://dredd.org/ or https://microcks.io/ Both support OpenAPI testing so you can specify the contract as an OpenAPI spec and validate your server against it.
There's also https://docs.pact.io/ but I haven't had time yet to really look into it but probably someone else can tell something about it.
Repo: https://github.com/testcontainers/testcontainers-go/