
| Current Path : /var/www/html/rocksensor1/web/core/tests/Drupal/Tests/Core/Extension/ |
Linux ift1.ift-informatik.de 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64 |
| Current File : /var/www/html/rocksensor1/web/core/tests/Drupal/Tests/Core/Extension/GenericTestExistsTest.php |
<?php
declare(strict_types=1);
namespace Drupal\Tests\Core\Extension;
use Drupal\Tests\UnitTestCase;
use Drupal\KernelTests\FileSystemModuleDiscoveryDataProviderTrait;
/**
* Tests that the Generic module test exists for all modules.
*
* @group Extension
*/
class GenericTestExistsTest extends UnitTestCase {
use FileSystemModuleDiscoveryDataProviderTrait;
/**
* Lists module that do not require a Generic test.
*/
protected $modulesNoTest = ['help_topics', 'sdc'];
/**
* Tests that the Generic module test exists for all modules.
*
* @dataProvider coreModuleListDataProvider
*/
public function testGenericTestExists(string $module_name): void {
if (in_array($module_name, $this->modulesNoTest, TRUE)) {
$this->markTestSkipped();
}
$this->assertFileExists("{$this->root}/core/modules/{$module_name}/tests/src/Functional/GenericTest.php");
}
}