class DeprecatedBackboneTest
Checks the deprecation status of Backbone.
@group Asset @group legacy
Hierarchy
- class \Drupal\KernelTests\KernelTestBase extends \Drupal\Core\DependencyInjection\ServiceProviderInterface uses \Drupal\KernelTests\AssertLegacyTrait, \Drupal\KernelTests\AssertContentTrait, \Drupal\Tests\RandomGeneratorTrait, \Drupal\Tests\ConfigTestTrait, \Drupal\Tests\ExtensionListTestTrait, \Drupal\Tests\TestRequirementsTrait, \Drupal\Tests\Traits\PhpUnitWarnings, \Drupal\Tests\PhpUnitCompatibilityTrait, \Symfony\Bridge\PhpUnit\ExpectDeprecationTrait implements \PHPUnit\Framework\TestCase
- class \Drupal\KernelTests\Core\Asset\DeprecatedBackboneTest implements \Drupal\KernelTests\KernelTestBase
Expanded class hierarchy of DeprecatedBackboneTest
File
-
core/
tests/ Drupal/ KernelTests/ Core/ Asset/ DeprecatedBackboneTest.php, line 13
Namespace
Drupal\KernelTests\Core\AssetView source
class DeprecatedBackboneTest extends KernelTestBase {
/**
* The library discovery service.
*
* @var \Drupal\Core\Asset\LibraryDiscoveryInterface
*/
protected $libraryDiscovery;
/**
* {@inheritdoc}
*/
protected function setUp() : void {
parent::setUp();
$this->libraryDiscovery = $this->container
->get('library.discovery');
}
/**
* Tests that the Backbone library is deprecated.
*/
public function testBackboneDeprecation() {
$this->libraryDiscovery
->getLibraryByName('core', 'backbone');
$this->expectDeprecation("The core/backbone asset library is deprecated in Drupal 9.4.0 and will be removed in Drupal 10.0.0.");
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.