CLI Reference

Complete command line interface reference for TestFlowKit

CLI Reference

tkit [command] [options]

Default config file: testflowkit.yml (falls back to legacy config.yml).

Commands

CommandDescription
tkit runExecute test scenarios
tkit validateValidate config and feature files
tkit initScaffold a new project
tkit installInstall browser driver (Playwright)
tkit export-step-definitionsExport step catalog as JSON
tkit versionShow version info

run

tkit run [options]
OptionShortDescriptionDefault
--config-cConfig file pathtestflowkit.yml
--location-lFeature files directoryfrom config
--tags-tTag filter expressionall
--env-fileEnvironment variables YAMLfrom config
--headlessHeadless browser modetrue
--timeoutRequest/element timeout (10s, 1m)from config
--debugLog full request/response payloadsfalse
tkit run
tkit run --tags @smoke
tkit run --tags "@login and not @slow"
tkit run --env-file .env.staging.yml
tkit run --config staging.yml --location e2e/features
tkit run --debug

validate

tkit validate [-c config] [-l location] [-t tags] [--env-file file]

install

Installs Playwright when frontend.driver: "playwright" is set in config. Rod requires no install.

tkit install
tkit install --config staging.yml

export-step-definitions

tkit export-step-definitions --format json > step-definitions.json

Used by the MCP server and for offline step catalog snapshots.

Tag expressions

tkit run --tags @smoke
tkit run --tags "@smoke and @login"
tkit run --tags "@smoke or @regression"
tkit run --tags "not @slow"
tkit run --tags "@smoke and not @wip"

Exit codes

CodeMeaning
0All tests passed
1Test failure
2Configuration error
3Invalid arguments

CI example

# GitHub Actions
- run: |
    npm install -g @testflowkit/cli
    tkit run --headless --tags @smoke

Next Steps