contractgates

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 1, 2026 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Overview

Package contractgates holds the SYNTHETIC-BREAK tests for the schema repo's breaking-change contract gates: oasdiff for the OpenAPI specs and go-apidiff for the exported Go API.

Each breaking gate (oasdiff for the OpenAPI specs, go-apidiff for the exported Go API) ships a test here that applies a KNOWN breaking mutation and asserts the gate binary exits non-zero / reports the break. This proves the gate actually fires — a gate that never fails is no gate at all.

The tests invoke the gate binaries directly (they are provisioned by the flake dev shell, not go.mod). When a binary is not on PATH — e.g. a bare `go test` run outside `nix develop` — the test t.Skip()s with an ACTIONABLE message telling the developer how to get the tool, rather than failing spuriously. Inside `nix develop -c make check` the binaries are present and the tests run for real.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL