public function ProjectUnitTest::projectNameDetectionProvider in Coder 8.3.x
Same name and namespace in other branches
- 8.3 tests/DrupalPractice/ProjectDetection/ProjectUnitTest.php \DrupalPractice\Test\ProjectDetection\ProjectUnitTest::projectNameDetectionProvider()
Data provider for testProjectNameDetection().
Return value
array<int, array<int, string|false>> An array of test cases, each test case an array with two elements:
- The filename to check.
- The expected project name.
File
- tests/
DrupalPractice/ ProjectDetection/ ProjectUnitTest.php, line 151
Class
- ProjectUnitTest
- Tests that project and version detection works.
Namespace
DrupalPractice\Test\ProjectDetectionCode
public function projectNameDetectionProvider() : array {
return [
[
__DIR__ . '/drupal6/testmodule.info',
'testmodule',
],
[
__DIR__ . '/drupal6/nested/test.php',
'testmodule',
],
[
__DIR__ . '/drupal7/testmodule.info',
'testmodule',
],
[
__DIR__ . '/drupal8/testmodule.info.yml',
'testmodule',
],
[
__DIR__ . '/drupal8/testtheme/testtheme.info.yml',
'testtheme',
],
[
__DIR__ . '/drupal8/testtheme/testtheme.theme',
'testtheme',
],
[
'invalid',
false,
],
];
}