gtms-cli

module
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2026 License: MIT

README

GTMS — Git-based Test Management System

One tester orchestrating what used to take an army, never touching a selector.

GTMS is a CLI tool that orchestrates AI coding agents through a three-stage pipeline:

CREATE test cases  →  AUTOMATE them  →  EXECUTE them

You write requirements. AI writes the tests. GTMS conducts the orchestra.

Install

Go install (recommended — requires Go 1.21+):

go install github.com/aitestmanagement/gtms-cli/cmd/gtms@latest

Download a binary from GitHub Releases, extract, and add to your PATH. On Windows, if SmartScreen shows "Windows protected your PC", click More info → Run anyway — SmartScreen reputation builds organically across the first few signed releases. See SIGNING.md for the signing policy and how to verify a binary.

Verify:

gtms version

Quick Start

# Initialise a project (in an existing git repo)
gtms init --name "My Project" --repo "org/my-repo" --adapter claude

# Create test cases from a requirement
gtms create login --reference REQ-001 --context-file requirements/login.md

# Automate a test case
gtms automate tc-f1a2b3c --framework playwright

# Run the automated test
gtms execute tc-f1a2b3c

# Check the pipeline
gtms status
gtms gaps

Commands

Command What it does
gtms init Scaffold a GTMS project (directories, config, templates)
gtms create <folder> Generate test cases from a requirement
gtms automate <tc-id> Generate automation for a test case
gtms execute <tc-id> Validate automated tests during development
gtms status [folder] Pipeline overview or detail for one test case
gtms gaps [folder] Coverage gap analysis
gtms triage <tc-id> Classify a failure and trigger follow-on action

How It Works

GTMS doesn't write tests or run them — it delegates to adapters. An adapter is any tool that can do the work: Claude, GPT, Copilot, a shell script, or anything else you configure.

# gtms.config
project:
  name: "My Project"
  repo: org/my-repo

adapters:
  create:
    local-claude:
      mode: sync
      prompt-template: test-cases/prompts/create-standard.md
      command: 'claude -p "Create test cases from the source material." --append-system-prompt-file {prompt_file}'
  automate:
    local-claude:
      mode: sync
      prompt-template: test-automation/prompts/automate-standard.md
      command: 'claude -p "Generate an automated test from the test case." --append-system-prompt-file {prompt_file}'
  execute:
    local-runner:
      mode: sync
      command: 'npx playwright test {artefact_file}'

defaults:
  create: local-claude
  automate: local-claude
  execute: local-runner

Two adapter tiers:

Tier Config How it works
1 command Variable substitution into a shell command template
2 script A script receives GTMS_* environment variables

See the Adapter Guide for the full reference.

What GTMS Is (and Isn't)

GTMS is a test development tool, not a test execution engine. gtms execute validates your tests during development — checking that what you've built works before you trust it. Once stable, your tests graduate into your real CI pipeline.

Git helps you develop code but doesn't run it in production. GTMS helps you develop tests but doesn't run them in production.

Requirements

  • Go 1.21+ (for building from source)
  • Git on PATH
  • An AI coding tool (Claude, GPT, Copilot, etc.) for create/automate adapters

Verifying Releases

Windows binaries are Authenticode-signed via SignPath Foundation. See SIGNING.md for the signing policy and verification instructions.

License

MIT

Directories

Path Synopsis
cmd
gtms command
internal
adapter
Package adapter handles adapter resolution, tier computation, and invocation.
Package adapter handles adapter resolution, tier computation, and invocation.
cli
Package cli defines the Cobra command tree for the GTMS CLI.
Package cli defines the Cobra command tree for the GTMS CLI.
config
Package config handles loading and validating the gtms.config file.
Package config handles loading and validating the gtms.config file.
execution
Package execution manages per-test execution results (CON-016 schema).
Package execution manages per-test execution results (CON-016 schema).
git
Package git provides shell-out wrappers around the git CLI.
Package git provides shell-out wrappers around the git CLI.
id
Package id generates unique 8-character hexadecimal identifiers for GTMS task files using crypto/rand.
Package id generates unique 8-character hexadecimal identifiers for GTMS task files using crypto/rand.
layout
Package layout centralises the GTMS-managed directory names so they are defined in one place.
Package layout centralises the GTMS-managed directory names so they are defined in one place.
link
Package link implements the core business logic for the gtms link command.
Package link implements the core business logic for the gtms link command.
output
Package output provides CLI formatting utilities including status icons, TTY detection, table formatting, and error output helpers.
Package output provides CLI formatting utilities including status icons, TTY detection, table formatting, and error output helpers.
pathsafe
Package pathsafe provides validation and containment helpers for filesystem paths that originate from caller-supplied identifiers, configuration, or automation records.
Package pathsafe provides validation and containment helpers for filesystem paths that originate from caller-supplied identifiers, configuration, or automation records.
pipeline
discover.go provides adapter-declared artefact discovery for the execute command's lazy automation-record creation (ENH-136).
discover.go provides adapter-declared artefact discovery for the execute command's lazy automation-record creation (ENH-136).
prompt
Package prompt handles template assembly for adapter invocations.
Package prompt handles template assembly for adapter invocations.
reader
Package reader implements the built-in local-reader adapter.
Package reader implements the built-in local-reader adapter.
result
Package result manages the lifecycle of handoff contracts.
Package result manages the lifecycle of handoff contracts.
scaffold
Package scaffold provides project scaffolding for gtms init.
Package scaffold provides project scaffolding for gtms init.
tapparse
Package tapparse classifies TAP (Test Anything Protocol) output lines.
Package tapparse classifies TAP (Test Anything Protocol) output lines.
task
Package task manages task file CRUD and state machine transitions.
Package task manages task file CRUD and state machine transitions.
testcase
Package testcase provides shared test-case existence validation.
Package testcase provides shared test-case existence validation.
wiring
Package wiring owns the tracked automation-wiring schema introduced by CON-023 / ENH-145.
Package wiring owns the tracked automation-wiring schema introduced by CON-023 / ENH-145.

Jump to

Keyboard shortcuts

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