Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,10 @@ jobs:
run: |
cd sdk/python
python -m uv run --extra dev pytest --cov=gait --cov-report=term-missing --cov-fail-under=85
- name: Tier 11 scenario suite
shell: bash
run: |
make test-scenarios

e2e:
needs: changes
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/pr-fast.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ jobs:
PYTHONPATH: .
run: |
make test-fast
- name: Validate scenario fixtures
run: |
bash scripts/validate_scenarios.sh

windows-fast:
name: pr-fast-windows
Expand Down
5 changes: 5 additions & 0 deletions CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,9 @@
/cmd/gait/** @davidahmann
/core/** @davidahmann
/schemas/** @davidahmann

# Scenario fixtures are contract artifacts and require explicit owner review.
# Changes under /scenarios/ should be reviewed for expected behavior drift.
/scenarios/ @davidahmann

/.github/workflows/** @davidahmann
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ BENCH_REGEX := Benchmark(EvaluatePolicyTypical|VerifyZipTypical|DiffRunpacksTypi
BENCH_OUTPUT ?= perf/bench_output.txt
BENCH_BASELINE ?= perf/bench_baseline.json

.PHONY: fmt lint lint-fast codeql test test-fast prepush prepush-full github-guardrails github-guardrails-strict test-hardening test-hardening-acceptance test-chaos test-e2e test-acceptance test-v1-6-acceptance test-v1-7-acceptance test-v1-8-acceptance test-v2-3-acceptance test-v2-4-acceptance test-v2-5-acceptance test-v2-6-acceptance test-voice-acceptance test-context-conformance test-context-chaos test-packspec-tck test-ui-acceptance test-ui-unit test-ui-e2e-smoke test-ui-perf test-adoption test-adapter-parity test-ecosystem-automation test-release-smoke test-install test-install-path-versions test-contracts test-intent-receipt-conformance test-ci-regress-template test-ci-portability-templates test-live-connectors test-skill-supply-chain test-runtime-slo test-ent-consumer-contract test-uat-local test-openclaw-skill-install test-beads-bridge test-docs-storyline test-docs-consistency test-demo-recording openclaw-skill-install build bench bench-check bench-budgets context-budgets skills-validate ecosystem-validate ecosystem-release-notes demo-90s demo-hero-gif homebrew-formula wiki-publish tool-allowlist-policy ui-build ui-sync ui-deps-check
.PHONY: fmt lint lint-fast codeql test test-fast test-scenarios prepush prepush-full github-guardrails github-guardrails-strict test-hardening test-hardening-acceptance test-chaos test-e2e test-acceptance test-v1-6-acceptance test-v1-7-acceptance test-v1-8-acceptance test-v2-3-acceptance test-v2-4-acceptance test-v2-5-acceptance test-v2-6-acceptance test-voice-acceptance test-context-conformance test-context-chaos test-packspec-tck test-ui-acceptance test-ui-unit test-ui-e2e-smoke test-ui-perf test-adoption test-adapter-parity test-ecosystem-automation test-release-smoke test-install test-install-path-versions test-contracts test-intent-receipt-conformance test-ci-regress-template test-ci-portability-templates test-live-connectors test-skill-supply-chain test-runtime-slo test-ent-consumer-contract test-uat-local test-openclaw-skill-install test-beads-bridge test-docs-storyline test-docs-consistency test-demo-recording openclaw-skill-install build bench bench-check bench-budgets context-budgets skills-validate ecosystem-validate ecosystem-release-notes demo-90s demo-hero-gif homebrew-formula wiki-publish tool-allowlist-policy ui-build ui-sync ui-deps-check
.PHONY: hooks
.PHONY: docs-site-install docs-site-build docs-site-lint docs-site-check

Expand Down Expand Up @@ -66,13 +66,17 @@ test-fast:
$(GO) test ./...
(cd $(SDK_DIR) && PYTHONPATH=. uv run --python $(UV_PY) --extra dev pytest)

test-scenarios:
$(GO) test ./internal/scenarios -count=1 -tags=scenario -v

prepush:
$(MAKE) lint-fast
$(MAKE) test-fast

prepush-full:
$(MAKE) lint
$(MAKE) test
$(MAKE) test-scenarios
$(MAKE) codeql

github-guardrails:
Expand Down
3 changes: 2 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@ module github.com/Clyra-AI/gait
go 1.25.7

require (
github.com/Clyra-AI/proof v0.3.0
github.com/Clyra-AI/proof v0.4.0
github.com/goccy/go-yaml v1.19.2
gopkg.in/yaml.v3 v3.0.1
)

require (
Expand Down
5 changes: 3 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
github.com/Clyra-AI/proof v0.3.0 h1:3AjRK3YqGuzWZCzhu6isXKr/EGNoOvo/kkkM4JFxNqI=
github.com/Clyra-AI/proof v0.3.0/go.mod h1:EDff6buidj222E+EYyqQXXj1rtPgSFlYOxl2JFfWKFs=
github.com/Clyra-AI/proof v0.4.0 h1:tcto9gVZeIA96eCQunnY5LICqg1bl+IkMR4i1k9Eg3o=
github.com/Clyra-AI/proof v0.4.0/go.mod h1:EDff6buidj222E+EYyqQXXj1rtPgSFlYOxl2JFfWKFs=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
Expand All @@ -15,6 +15,7 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA=
github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
Expand Down
35 changes: 35 additions & 0 deletions internal/scenarios/fixtures.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
package scenarios

import (
"fmt"
"os"
"path/filepath"
)

const scenarioRootRelativePath = "scenarios/gait"

var requiredScenarioMinimumFiles = map[string][]string{
"policy-block-destructive": {"README.md", "policy.yaml", "intents.jsonl", "expected-verdicts.jsonl"},
"policy-allow-safe-tools": {"README.md", "policy.yaml", "intents.jsonl", "expected-verdicts.jsonl"},
"dry-run-no-side-effects": {"README.md", "policy.yaml", "intent.json", "flags.yaml", "expected.yaml"},
"concurrent-evaluation-10": {"README.md", "policy.yaml", "intent.json", "flags.yaml", "expected.yaml"},
"pack-integrity-round-trip": {"README.md", "expected.yaml"},
"delegation-chain-depth-3": {"README.md", "policy.yaml", "intent.json", "flags.yaml", "expected.yaml", "delegation-token-1.json", "delegation-token-2.json", "delegation-token-3.json", "delegation_public.key"},
"approval-expiry-1s-past": {"README.md", "policy.yaml", "intent.json", "expected.yaml", "approval-token.json", "approval_public.key"},
"approval-token-valid": {"README.md", "policy.yaml", "intent.json", "expected.yaml", "approval-token.json", "approval_public.key"},
}

func findRepoRoot(startDir string) (string, error) {
current := startDir
for {
candidate := filepath.Join(current, "go.mod")
if info, err := os.Stat(candidate); err == nil && !info.IsDir() {
return current, nil
}
parent := filepath.Dir(current)
if parent == current {
return "", fmt.Errorf("unable to locate repository root from %s", startDir)
}
current = parent
}
}
Loading
Loading