Skip to content

Configuration

Reference

Use impact-gate.config.json to pin analysis defaults, route the tool to the right tests root, and make CI behavior predictable across pull requests, release branches, and local runs.

Config purpose

Use config when you want repeatable team defaults

Auto-detection is great for onboarding, but config is what makes CI, release branches, and local runs behave the same way across the team.

File names

The CLI looks for these files automatically

impact-gate.config.json .impact-gate.config.json

Create impact-gate.config.json (or .impact-gate.config.json) in your project root. The CLI auto-discovers it by walking upward from the current directory.

Full Config Example

{
"path": ".",
"profile": "default",
"testsRoot": "./e2e-tests",
"mode": "impact",
"framework": "auto",
"git": {
"since": "origin/main"
},
"impact": {
"dependencyGraph": {
"enabled": true,
"maxDepth": 3
},
"traceability": {
"enabled": true
},
"aiFlow": {
"enabled": true,
"provider": "anthropic"
}
},
"pipeline": {
"enabled": false,
"scenarios": 3,
"outputDir": "specs/functional/ai-assisted",
"mcp": false
},
"policy": {
"enforcementMode": "advisory",
"blockOnActions": ["must-add-tests"]
}
}

Field Reference

Top-Level

FieldTypeDefaultDescription
pathstring.Project root directory
profilestringdefaultAnalysis profile: default or strict
testsRootstringauto-detectedPath to tests directory
modestringimpactDefault analysis mode
frameworkstringautoTest framework (playwright, cypress, pytest, supertest, selenium, auto)

git

FieldTypeDefaultDescription
sincestringauto-detectedGit ref for diff base (e.g., origin/main)

impact

FieldTypeDefaultDescription
dependencyGraph.enabledbooleantrueEnable static reverse-dependency analysis
dependencyGraph.maxDepthnumber3Max depth for transitive impact traversal
traceability.enabledbooleantrueUse CI execution data for file-to-test mapping
aiFlow.enabledbooleantrueEnable LLM-powered flow mapping
aiFlow.providerstringautoLLM provider for AI enrichment

pipeline

FieldTypeDefaultDescription
enabledbooleanfalseEnable test generation pipeline
scenariosnumber3Number of test scenarios to generate per gap
outputDirstring—Directory for generated specs
mcpbooleanfalseUse Playwright MCP server for generation

policy

FieldTypeDefaultDescription
enforcementModestringadvisoryadvisory, warn, or block
blockOnActionsstring[][]Actions that trigger blocking (run-now, must-add-tests, safe-to-merge)

advisory

The isolated plan --advisory caller requires this top-level object and a --suite ID. See the Mattermost guide and source configuration.

FieldRequired value
repositoryGitHub owner/repo, matching the checkout origin
sourcePatternsRepository-relative product-source globs
crossCuttingPatternsRepository-relative globs that require full fallback
suitesDistinct entries with id, framework, root, configFile, project, browser, variant, specPattern, and optional exclude
mappingsCandidate entries with sourcePattern, suite ID, exact specs, and declared provenance: {kind, evidence}; may be empty

Spec patterns and exclusions are relative to the suite root and include dot paths. Absolute paths, traversal and leading !/# patterns are rejected. Configuration is read as data, not evaluated as framework code. Declared human review, static inference and co-change evidence remain unverified; every nonempty diff retains full fallback. The report fingerprints the inputs but does not authenticate their reviewer or runtime environment.

policy.enforcementMode: "advisory" only changes ordinary plan enforcement. It does not activate the isolated, provider-free, no-write contract; use the CLI --advisory flag for that.

Profiles

Profile

default

Standard analysis behavior for most repositories.

Profile

strict

Uses stricter handling for heuristic-only mappings and more opinionated analysis defaults when you want tighter gating.

Framework auto-detection is separate from profiles. The CLI can auto-detect Playwright, Cypress, pytest, supertest, and Selenium usage from project files and dependencies.

Precedence

CLI flags override config file values, which override auto-detected defaults.