Skip to main content

Automated tests

Learn how to automate ongoing testing and make sure your Actors perform over time. See code examples for configuring the Actor Testing Actor.


Automated tests for Actors

Automated testing is crucial for maintaining the reliability and performance of your Actors over time. This guide will help you set up automated tests using the Actor Testing Actor.

Set up automated tests

  1. Prepare test tasks - Create 1–5 separate testing tasks for your Actor.
  2. Configure Actor testing - Set up a task using the Actor Testing Actor.
  3. Validate tests - Run the test task multiple times until all tests pass.
  4. Schedule tests - Set up a recurring schedule for your tests.
  5. Monitor results - Review and address any issues on a weekly basis.

Create test tasks

Example of Actor testing tasks

When creating test tasks:

  • Include a test for your Actor's default configuration
  • Set a low maxItem value to conserve credits
  • For large data tests, reduce test frequency to conserve credits

Configure the Actor Testing Actor

Follow the setup guide in the Actor's README.

Here are some recommended test scenarios:

await expectAsync(runResult).toHaveStatus('SUCCEEDED');