Summer ’25 lets you run Flow Tests from the Salesforce CLI using the new sf flow run test command — ideal for CI/CD and automated regression testing.
Run Flow Tests from the CLI
Summer ’25 introduces a simple CLI command to execute Salesforce Flow Tests: sf flow run test. This lets teams run flow unit and regression tests programmatically as part of local scripts, CI pipelines, or release automation — removing the need to trigger tests manually in Flow Builder.
Why this matters
Automating Flow Tests helps catch errors earlier, reduces manual effort, and improves release confidence. Especially for organizations using DevOps practices, adding Flow Tests to CI/CD ensures flows behave as expected before they reach production.
How to use
- Open your terminal in a Salesforce DX project or authenticated org.
- Run:
sf flow run test
— this will execute all flow tests available in the org. - Integrate the command into CI jobs (GitHub Actions, GitLab CI, Jenkins) to run tests automatically during builds or before deployments.
Best practices
- Keep flow tests small and focused so failures point to specific behavior.
- Combine with source-driven development: run tests on feature branches and pull requests.
- Fail fast in CI: abort deployment on test failures and surface clear logs for developers.
Use cases include regression testing after flow changes, validating flows during release pipelines, and running nightly test suites as part of quality gates.
Next steps
If you haven’t already, add flow tests in Flow Builder and then wire the sf flow run test
command into your pipeline. This change from Summer ’25 makes flow automation testing a first-class part of Salesforce CI/CD.
For Salesforce admins, developers, and release engineers, this update reduces manual testing overhead and increases deployment reliability.
#SalesforceSummer25 #Flows #DevOps #CI #Salesforce
For more, please follow our page!
Leave a Reply