Skip to main content

Testmode

DrevOps\BehatSteps\Steps\Drupal\TestmodeTrait - Source, Example, Helpers

Configure Drupal Testmode module for controlled testing scenarios.

Skip processing with tag: @behat-steps-skip:TestmodeTrait.

Special tags:

  • @testmode - enable for scenario

Prerequisites​

PrerequisiteCapability
A backend in the scenario's list provides "StateCapabilityInterface"StateCapabilityInterface
A backend in the scenario's list provides "CacheCapabilityInterface"CacheCapabilityInterface
The "testmode" module from the "drupal/testmode" package is enabledModuleCapabilityInterface

Options​

OptionTypeDefaultTagDescription
testmode.enabledbooleanTRUE@behat-steps-skip:TestmodeTraitIf TRUE, switches the Testmode module's test mode on for a @testmode scenario and off after it finishes. If FALSE, the tag does nothing.