When tests fail, you can tag owners in the Slack notification. Ownership rules are defined in a .empiricalrun/OWNERS.yaml file in your test repo.
Setup
Create .empiricalrun/OWNERS.yaml in the root of your test repository.
rules:
- match: { tag: "@payments" }
owners:
- slack: "U04ABCDEF"
Each rule has a match condition and a list of owners to mention.
Matching
By tag (exact match)
- match: { tag: "@payments" }
owners:
- slack: "U04ABCDEF" # Alice
- slack: "S07XYZ" # #payments-team group
By file path (exact)
- match: { file: "tests/checkout.spec.ts" }
owners:
- slack: "U04ABCDEF"
By directory (glob)
# All tests under tests/checkout/
- match: { file: "tests/checkout/**" }
owners:
- slack: "U04ABCDEF"
By filename pattern (wildcard)
# All spec files directly in tests/api/
- match: { file: "tests/api/*.spec.ts" }
owners:
- slack: "U04ABCDEF"
* matches within a single directory, ** matches across directories.
All tests (catch-all)
- match: { file: "**" }
owners:
- slack: "U04ONCALL"
Use the Slack member ID or user group ID directly:
- User:
U04ABCDEF (find via Slack profile → Copy member ID)
- User group:
S07XYZ (find via Slack admin → User groups)
The full mention syntax (<@U04ABCDEF>, <!subteam^S07XYZ>) is also supported.
Behavior
- Rules are evaluated top-down; a test can match multiple rules
- All matched owners are mentioned (deduplicated)
- If
OWNERS.yaml is missing or invalid, notifications are sent without mentions