Starting with mabl CLI version 2.82.10, you can trigger local and CI runs of tests that contain visual assertions. With this enhancement, you can run more complex visual validations earlier in the development cycle!
To enable visual assertions for your local browser or mobile test runs, use the --allow-billable-features option. For example:
mabl tests run --id {test-id} --allow-billable-featuresPromotional period
For the foreseeable future, local CLI and CI executions can run visual assertions at no additional credit cost.
When the --allow-billable-features option is enabled, local and CI runs output the assertion criteria and resulting analysis and evaluation from visual assertion steps. Test runs are subject to the same 30-assertion-per-run limit as cloud runs. If this limit is exceeded, any additional visual assertions will fail.
By default, the allow-billable-features option is disabled. When disabled, visual assertions are failed with the following message: "AI assertions are not available in CLI runs by default. Use –allow-billable-features to enable, failing assertion."
Try it out
To try it out, update the mabl CLI to version 2.82.10 or later:
npm install -g @mablhq/mabl-cliTo trigger a local or CI run of browser tests with visual assertions, use the mabl tests run command. For example:
mabl tests run
--labels smoke
--allow-billable-featuresTo trigger a local or CI run of mobile tests with visual assertions, use the mabl tests run-mobile command. For example:
mabl tests run-mobile
--labels wip
--build-file-id {build-file-id}
--allow-billable-featuresOther ways to run tests locally with visual assertions:
- mabl Desktop App - trigger a local ad hoc run from the Desktop App.
-
mabl MCP - for local MCP runs with #run_mabl_test_local, you can enable visual assertions with the
allowLocalTestBilling: trueflag. Note that while local test runs triggered from the MCP return a test status, they do not output step level results, such as the detailed output and evaluation of visual assertion steps.