StrikekitStrikekit

First test

Write and run a simple .stk scenario

Create a file

Save as login.stk:

Group: Authentication

    Scenario: User login happy path
        Given I navigate to "https://example.com/login"
        When I fill "username" with "chamodh"
        And I fill "password" with "1234"
        And I click on "Login"
        Then I should see "Welcome back"

Every web scenario needs a starting page via navigate to "…". Use a full URL or an environment variable such as "$BASE_URL". There is no STK_BASE_URL.

Run it

strikekit run login.stk
strikekit run --browsers chrome login.stk
strikekit run --headed --browsers chrome login.stk

Progress appears on stderr. Structured NDJSON events go to stdout.

Labels, not selectors

Quoted values like "username" and "Login" are plain labels. StrikeTest finds elements automatically (id, data-testid, aria-label, visible text, and related strategies). Do not put CSS or XPath in .stk files.

Step prefixes

PrefixMeaning
Given IPrecondition / starting state
When IPrimary user action
And IContinuation of the previous step type
Then IAssertion / expected outcome

The I is optional when you type; the formatter always outputs the canonical Given I / When I / And I / Then I form.

Filter runs

# Only scenarios tagged @smoke
strikekit run --tag smoke login.stk

# Only when Group: matches
strikekit run --group "Authentication" login.stk

Tag scenarios on the Scenario: line:

Scenario: User login @smoke

Next

On this page