New in 2.0.x.

In order to successfully run tests, the environment under test must be prepared in some ways, such as:

  • Automated Testing must be installed and enabled;
  • QA Accounts must be enabled;
  • Probably some other custom conditions for your site.

Automated Testing Kit allows to check the prerequisites before running all tests.

They are defined in data/atk_prerequisites.yml in the following format:

- command: 'pm:list --format=json'
  message: 'Automated Testing Kit, QA Accounts must be enabled. (See data/atk_prerequisites.yml for details)'
  json:
    automated_testing_kit.status:
      eq: 'Enabled'
    qa_accounts.status:
      eq: 'Enabled'

 Format is the following:

  • command - A Drush command to execute,
  • message - Message to show if prerequisite check is failed;
  • json - Currently we support only commands that return JSON. Use --format=json in Drush command for it. This contains an Object of fields and conditions to these fields, in the example above property automated_testing_kit.status should be equal "enabled".