Testing Automations

Use this guide to safely test automation rules in the app before you turn them on, and to validate updates to existing rules. The steps below help ecommerce retailers, 3PLs, and brands:

  • Reduce order-flow disruptions by validating logic up front
  • Improve accuracy by confirming the right entities trigger the right actions
  • Save time by using built-in tools, with no sandbox or separate environment required

There is no single "test automation" button. Effective testing combines three capabilities:

  • Test filter and Test code to confirm rule conditions and code actions
  • Test entities (orders, products, and so on) to simulate real scenarios
  • Automation History to monitor execution, timing, and errors

Before You Begin

  • Keep new or edited rules disabled until you've tested their filters and code.
  • When validating a rule in production, create the rule normally and add a test identifier to your filter, such as checking for an automation-test tag to isolate test orders.
  • Start with narrow filters to limit scope, then broaden gradually.
  • Know rule execution behavior: rules are checked top to bottom. On New Orders and Modified Exceptions, only the first matching rule runs.
  • Know where to monitor: go to Automations > History to review every run.

How Testing Works

  • Test filter: Checks whether a single record passes your rule's filter before you enable the rule.
  • Test entities: Real records in your account (for example, a test order) that meet your filter conditions.
  • Automation runs: A log of each time an automation processes a record, including the rules that ran, steps, status, timing, and errors. To see runs, go to Automations > History.

Testing Automations

There are several ways to test your automation rules:

1. Built-in Testing Tools

The automation rule editor includes testing tools:

  • Test filter: Opens Test Automation Rule Filter. Click Load latest order, or enter an order ID and click Load, and edit the JSON if needed. The output shows Passed ("The input passed through the filter") or Failed ("The input did not pass through the filter"). For Code (JavaScript) filters, click Test code instead.

1.webp

  • Test code (code actions): For Update Order by Code (JavaScript) and other code actions, click Test code to open Test Automation Rule Action. Load an order, run your code, and review the output before any real data changes. Use console.log to write to the Debug panel.

2.webp

  • Convert filter to code: Turn a Simple filter into JavaScript, then customize it for more complex scenarios. Click View summary to see any filter in plain language.

3.webp

2. Test with Real Orders

You can test automations using actual orders in a controlled way:

  1. Create a test order in your sales channel with a specific tag (for example, pipe17_test).
  2. Limit what your selling channel integration pulls. Go to Integrations, open the integration, and use its order settings (for example, filters by order ID or by tag, or a cut-off date for older orders) so only your test order comes in. Setting names vary by integration.
  3. Pull the test order. Wait for the next scheduled pull, or, on the integration's Integration Actions tab, run the action that pulls orders by ID, if your integration has one.
  4. Monitor the automation. Go to Automations > History, find the run, and check its Status, Rules, and Error Message. Use View JSON to see the steps and full details.

3. Review Automation History

The Automations > History page is essential for testing and troubleshooting:

4.webp

  • Filter by entity type, status, and time period.
  • See which rules ran and what actions were taken.
  • Inspect error messages if something went wrong.
  • To understand a filter, click View summary in the rule, or open Ask Pippen at the top of the page and ask about it.

Steps

1. Create Your Test

  • Define the scenario (for example, "Route orders over $500 with expedited shipping").
  • Set acceptance criteria (for example, "Only orders tagged automation-test and subtotal > $500 trigger Rule A").
  • Decide which fields you will verify after the run (destination, tags, fulfillment routing, step outputs).

2. Create Safe Test Entities

  • Create one or more test orders or products that match your intended filters.
  • Add a distinct tag (for example, automation-test) or a unique value (for example, a SKU suffix) to isolate test data.

3. Validate the Rule with Test Filter

  • Open your rule (keep it disabled).
  • Click Test filter (or Test code for a code filter), load your test order, and confirm the output is Passed.
  • Load an order that shouldn't match and confirm the output is Failed.
  • If either result is wrong, refine the filter and test again.

4. (Optional) Learn from Automation History

Use existing runs to confirm how similar scenarios behaved:

  • Check the Rules column (or automationRuleIds in View JSON) to see which rules actually ran.
  • Review step order, results, and timing to anticipate outcomes for your new rule.

5. Enable the Rule for a Controlled Test

  • Enable the rule.
  • Create a new test entity that matches the filter.
  • Keep volumes low (one or two entities) to limit impact.

6. Monitor the Execution in Automation History

Open the latest run for your test entity, click View JSON, and verify:

  • Rules that ran: Confirm the expected rule ran (check automationRuleIds).
  • Step sequence: Confirm actions ran in the intended order.
  • Status per step: Each step shows PENDING, COMPLETED, or FAILED.
  • Timing: Compare createdAt and completedAt to gauge duration.
  • Attempts: execCount shows how many times the run was attempted. A failed run is retried on later checks.
  • Errors: Review errorMessage and failedAt if a step fails.

7. Validate the Outcome

  • Confirm the entity's final state (for example, tags applied, routing decisions, or updates to external systems).
  • If results differ from expectations, adjust the rule filter or action settings and test again.

8. Expand Scope Safely

  • Remove the test-only tag from the filter, or add additional conditions.
  • Run Test filter again against a few typical orders to confirm the broader scope.
  • Monitor results closely as volume increases.

9. Validate the Code

  • When you use code filters or code actions, check that the code works in all situations.
  • For example, when adding a tag to an order using code, make sure it works if the order has no tags field, an empty tags field, or existing tags.
  • Decide whether to turn on Abort on error. When it's on and the code fails, the order moves to Review Required, later rules don't run, and the app raises an eAutomationCodeActionError exception on the order.

Best Practices

  • Start disabled: New rules start disabled by default. Test first to avoid impacting production flow.
  • Use specific test filters: Target your automation-test tag or other unique identifiers.
  • Test rule interactions: Rules are checked top to bottom, and on New Orders and Modified Exceptions only the first matching rule runs, so verify the order carefully.
  • Monitor resilience: Review failed runs. Investigate runs with execCount above 1 and recurring errorMessage patterns.
  • Test edge cases: Boundaries (for example, $499.99 vs. $500), missing data, uncommon carriers, split shipments, or partial fulfillments.

Troubleshooting

  • The rule did not trigger
    Confirm the test entity matches the filter using Test filter. Check rule order, because a rule above may have matched first. Also check that the rule is on the right trigger tab for your scenario (for example, New Orders vs. Updated Orders).
  • The run shows FAILED on a step
    Open the run's View JSON and read errorMessage for the exact cause. Check failedAt and the surrounding timestamps for timing issues or external delays, and look for missing credentials, mapping errors, or unavailable services. Check execCount to see if a later attempt succeeded. If not, fix the root cause and test again.
  • Performance is slower than expected
    Compare createdAt and completedAt to isolate slow runs, and look for patterns across runs. Temporarily reduce scope (for example, to the automation-test tag) and measure again.
  • The filter matches too many or too few entities
    Simplify complex conditions and check each one with Test filter. Use exact values (for example, exact tags, SKUs, or order amounts) before you introduce ranges or wildcards.

Example Testing Approach

  1. Create a test order with the tag automation-test.
  2. Build a rule that filters for orders where Tags Equals Any Of automation-test. Keep the rule disabled.
  3. Click Test filter, load your test order, and confirm the output is Passed. Load another order and confirm it's Failed.
  4. Enable the rule.
  5. Create a second test order with the same tag.
  6. Go to Automations > History and review the new run: the rule that ran, step statuses, timing, and any errors.
  7. Confirm the order was updated as expected. Adjust and repeat as needed.

Need Help?

If you need additional assistance:

  • Use Ask Pippen, our AI agent, located at the top of the platform page.
  • Submit a support request with as much relevant detail as possible. Learn how to submit a request.

We're here to help you succeed with your operations.

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Article is closed for comments.

Have more questions?
Submit a request
Share it, if you like it.