You are here

protected function Domain301RedirectFunctionalTestTrait::disableRedirect in Domain 301 Redirect 8

Disable the domain 301 redirect.

1 call to Domain301RedirectFunctionalTestTrait::disableRedirect()
Domain301RedirectTest::testDomainRedirect in tests/src/Functional/Domain301RedirectTest.php
Test redirecting to various domains.

File

tests/src/Traits/Domain301RedirectFunctionalTestTrait.php, line 28

Class

Domain301RedirectFunctionalTestTrait
Common functions used by domain_301_redirect tests.

Namespace

Drupal\Tests\domain_301_redirect\Traits

Code

protected function disableRedirect() {
  $config = $this->configFactory
    ->getEditable('domain_301_redirect.settings');
  $config
    ->merge([
    'enabled' => 0,
  ])
    ->save();
  drupal_flush_all_caches();
}