You are here

public function ConfigInstallProfileUnmetDependenciesTest::testInstalled in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/config/tests/src/Functional/ConfigInstallProfileUnmetDependenciesTest.php \Drupal\Tests\config\Functional\ConfigInstallProfileUnmetDependenciesTest::testInstalled()

Confirms that the installation succeeded.

File

core/modules/config/tests/src/Functional/ConfigInstallProfileUnmetDependenciesTest.php, line 87

Class

ConfigInstallProfileUnmetDependenciesTest
Tests install profile config overrides can not add unmet dependencies.

Namespace

Drupal\Tests\config\Functional

Code

public function testInstalled() {
  if ($this->expectedException) {
    $this
      ->assertStringContainsString('Configuration objects provided by <em class="placeholder">testing_config_overrides</em> have unmet dependencies: <em class="placeholder">system.action.user_block_user_action (does_not_exist)</em>', $this->expectedException
      ->getMessage());
    $this
      ->assertStringContainsString('Drupal\\Core\\Config\\UnmetDependenciesException', $this->expectedException
      ->getMessage());
  }
  else {
    $this
      ->fail('Expected Drupal\\Core\\Config\\UnmetDependenciesException exception not thrown');
  }
}