Skip to main content
Use these recipes to give a test realistic inputs: fake values that change on every run, or a fixed set of inputs that runs the same test once per row.

Generate fake data

Momentic preloads the Faker library in every step that accepts templating, and in JavaScript steps via the faker global.

Inline via templating

Use {{ }} expressions in fields that support templating, such as typed values, target descriptions, and AI action goals:

Persist to the environment

For complex objects or values used across many steps, set them once in a JavaScript step:
Then reference it in later steps: {{ env.FAKE_PERSON.firstName }}.

Run tests against multiple inputs

Declare test parameters and supply their values in a CSV to run the same test once per row. Use this for login matrices, pricing tiers, or locale variations.
1

Declare parameters

Add a parameters key to your test file. Parameters become available as env.<NAME> inside steps.
inputs-test.test.yaml
Each entry is { name, required?, default?: { string } }. Add a default when the test should run without the parameter supplied:
2

Create a CSV

The first row is the header (parameter names). Each subsequent row is one run.
inputs.csv
3

Run it

Momentic runs the test once per CSV row. It substitutes the column values into env.