You are here

public function DependencyTest::testProjectNamespaceForDependencies in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/system/tests/src/Functional/Module/DependencyTest.php \Drupal\Tests\system\Functional\Module\DependencyTest::testProjectNamespaceForDependencies()

Checks functionality of project namespaces for dependencies.

File

core/modules/system/tests/src/Functional/Module/DependencyTest.php, line 22

Class

DependencyTest
Enable module without dependency enabled.

Namespace

Drupal\Tests\system\Functional\Module

Code

public function testProjectNamespaceForDependencies() {
  $edit = [
    'modules[filter][enable]' => TRUE,
  ];
  $this
    ->drupalPostForm('admin/modules', $edit, t('Install'));

  // Enable module with project namespace to ensure nothing breaks.
  $edit = [
    'modules[system_project_namespace_test][enable]' => TRUE,
  ];
  $this
    ->drupalPostForm('admin/modules', $edit, t('Install'));
  $this
    ->assertModules([
    'system_project_namespace_test',
  ], TRUE);
}