A practical business guide

How to make synthetic test data for an automation

Create fictional test records from your workflow rules and check the outcomes in an isolated workspace.

Download the worksheet ↧

Start with the rule you want to check

Build test records from your workflow rules. Use invented values that have the same structure as the inputs the workflow expects. For each rule, keep one record that passes, one that fails, and records at the points where the expected result changes. Write the expected result before you run any of them.

Ask the workflow owner for field names, allowed types, valid choices, and routing rules. A written field specification is enough to start. Keep production exports, real identifiers, contact details, and free-text notes out of the fixture. If you cannot reproduce a reported failure without the original record, ask the data owner to handle it under the approved process.

Make a small set that isolates each decision

  1. Choose one ordinary record that exercises the expected route. Give it a fixture ID that only appears in the test workspace.
  2. Copy that record for each new case. Change one field or condition so you can tell which rule explains a failure.
  3. For a range rule, test both endpoints and the nearest values outside the range. Test a missing field separately from a wrong type.
  4. Give every case an expected route and a count of expected side effects. If you test a retry or duplicate, state which earlier case it repeats and whether the prior result should be reused.

Keep invented values within any other requirements of the system. If the workflow uses email addresses as data, use reserved example domains for display or validation. Route outbound messages to a controlled test inbox or stub. A sample address by itself cannot isolate the sending step.

Fictional example: parts requests at Juniper Bench

This example is fictional. A small workshop wants to route stock requests. Its input rule requires a request_id and a units value that is an integer from 1 to 20 inclusive. The test version records what it would do in a private test log. A valid input creates one test ticket. An invalid input goes to review and creates zero test tickets.

For the ordinary case, use {"request_id":"SYN-01","units":8}. Give each variant its own request ID so a duplicate check cannot hide the result of validation. Keep those IDs different even when two cases use the same field value.

Test records for the workshop intake rule
CaseUnits fieldExpected routeNew tickets
SYN-018Accept1
SYN-021Accept1
SYN-0320Accept1
SYN-040Review0
SYN-0521Review0
SYN-06Field omittedReview0
SYN-07"8" (text)Review0

Across one clean run, expect three new tickets and four review events. If the input layer converts text to numbers before validation, check that behavior at the workflow entry point. If conversion is intentional, update the written rule and the expected outcome together. A test that injects a parsed value later in the workflow cannot confirm what the entry point accepts.

The JSON Schema object reference explains how to make a field required. Its numeric reference explains integer types and inclusive minimum and maximum limits. The reserved domain specification lists names intended for examples and testing.

Run against a safe destination and check the result

Before sending a fixture, confirm the trigger, credentials, destination, and alert route belong to the test workspace. Turn off or replace customer email, payment, and other live actions. Reset the test log or tag the new run so you can count only the effects for that run. Use the same input format and entry point that the workflow will receive in service.

Compare the actual route and the destination record with the expected outcome. For a rejected input, confirm zero new tickets as well as the review event. Save the fixture, expected result, actual result, and rule version. Add cases when you find a new failure that changes a decision. The acceptance test guide covers the evidence and sign-off that follow these checks.

SYNTHETIC TEST DATA WORKSHEET
Workflow and rule version:
Entry point and required fields:
Input type, allowed values, and boundaries:
Test destination and disabled live effects:
Normal case ID / input / expected route and effects:
Lower boundary / expected route and effects:
Upper boundary / expected route and effects:
Below and above range / expected outcomes:
Missing or wrong-type input / expected outcomes:
Actual route, destination effect count, and evidence:
Unexpected result / owner / next test:

For help defining and testing the rules before a live build, see Workflow Automation or book a workflow fit call. Bring a redacted rule description and one invented example.

Put the plan to work

Start with one useful change.

Bring the process, the people involved, and a redacted example. A free 30-minute fit call can establish the next step.