You are here

public function FeatureContext::before in Open Social 8.2

Same name and namespace in other branches
  1. 8 tests/behat/features/bootstrap/FeatureContext.php \FeatureContext::before()

@BeforeScenario

Parameters

\Behat\Behat\Hook\Scope\BeforeScenarioScope $scope:

File

tests/behat/features/bootstrap/FeatureContext.php, line 45

Class

FeatureContext
Defines application features from the specific context.

Code

public function before(BeforeScenarioScope $scope) {

  // Let's disable the tour module for all tests by default.
  \Drupal::configFactory()
    ->getEditable('social_tour.settings')
    ->set('social_tour_enabled', 0)
    ->save();

  /** @var \Behat\Testwork\Environment\Environment $environment */
  $environment = $scope
    ->getEnvironment();
  $this->minkContext = $environment
    ->getContext('SocialMinkContext');
}