a06f331eb8
CI / benchmark (push) Has been skipped
install-script / posix-syntax (push) Successful in 6m1s
CI / build-onnx (push) Failing after 6m43s
init-smoke / dry-run (push) Failing after 15m57s
security / govulncheck (push) Has been cancelled
security / trivy-fs (push) Has been cancelled
CI / test (1.26, ubuntu-latest) (push) Has been cancelled
Scorecard supply-chain security / Scorecard analysis (push) Has been cancelled
CI / test (1.26, macos-latest) (push) Has been cancelled
CI / build-windows (push) Has been cancelled
CI / lint (push) Has been cancelled
install-script / powershell-syntax (push) Has been cancelled
install-script / install (macos-14) (push) Has been cancelled
install-script / install (ubuntu-latest) (push) Has been cancelled
39 lines
975 B
Go
39 lines
975 B
Go
package main
|
|
|
|
import (
|
|
"bytes"
|
|
"strings"
|
|
"testing"
|
|
)
|
|
|
|
// TestGuideCmd_PrintsRelocatedReference verifies the `gortex guide` verb
|
|
// returns the relocated reference content — the CLI path for harnesses
|
|
// without MCP-resource support.
|
|
func TestGuideCmd_PrintsRelocatedReference(t *testing.T) {
|
|
run := func(args ...string) string {
|
|
var buf bytes.Buffer
|
|
guideCmd.SetOut(&buf)
|
|
guideCmd.SetErr(&buf)
|
|
guideCmd.Run(guideCmd, args)
|
|
return buf.String()
|
|
}
|
|
|
|
full := run()
|
|
if !strings.Contains(full, "# Gortex Guide") {
|
|
t.Error("full guide missing header")
|
|
}
|
|
if !strings.Contains(full, "bedrock` / `deepseek`") {
|
|
t.Error("full guide missing the provider matrix")
|
|
}
|
|
|
|
providers := run("providers")
|
|
if !strings.Contains(providers, "AWS Bedrock Converse") {
|
|
t.Error("`gortex guide providers` missing provider detail")
|
|
}
|
|
|
|
analyze := run("analyze")
|
|
if !strings.Contains(analyze, "analyze") {
|
|
t.Error("`gortex guide analyze` missing the analyze catalog")
|
|
}
|
|
}
|