
| Current Path : /var/www/html/stolberg/web/core/tests/Drupal/KernelTests/Core/Test/ |
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/stolberg/web/core/tests/Drupal/KernelTests/Core/Test/TestSetupTraitTest.php |
<?php
declare(strict_types=1);
namespace Drupal\KernelTests\Core\Test;
use Drupal\Core\Test\TestSetupTrait;
use Drupal\KernelTests\KernelTestBase;
/**
* Tests the TestSetupTrait trait.
*
* @coversDefaultClass \Drupal\Core\Test\TestSetupTrait
* @group Testing
*
* Run in a separate process as this test involves Database statics and
* environment variables.
* @runTestsInSeparateProcesses
* @preserveGlobalState disabled
*/
class TestSetupTraitTest extends KernelTestBase {
use TestSetupTrait;
/**
* @covers ::getDatabaseConnection
* @group legacy
*/
public function testGetDatabaseConnection(): void {
$this->expectDeprecation('Drupal\Core\Test\TestSetupTrait::getDatabaseConnection is deprecated in drupal:10.1.0 and is removed from drupal:11.0.0. There is no replacement. See https://www.drupal.org/node/3176816');
$this->assertNotNull($this->getDatabaseConnection());
}
}