You are here

protected function EditorFileReferenceFilterTest::setUp in CDN 8.3

Overrides KernelTestBase::setUp

File

tests/src/Kernel/EditorFileReferenceFilterTest.php, line 39

Class

EditorFileReferenceFilterTest
Tests the CDN module's Editor module's file reference filter.

Namespace

Drupal\Tests\cdn\Kernel

Code

protected function setUp() : void {
  parent::setUp();
  $this
    ->installConfig([
    'system',
    'cdn',
  ]);
  $this
    ->config('cdn.settings')
    ->set('mapping', [
    'type' => 'simple',
    'domain' => 'cdn-a.com',
  ])
    ->set('farfuture', [
    'status' => FALSE,
  ])
    ->save();
  $this
    ->installEntitySchema('file');
  $this
    ->installSchema('file', [
    'file_usage',
  ]);
  $manager = $this->container
    ->get('plugin.manager.filter');
  $bag = new FilterPluginCollection($manager, []);
  $this->filters = $bag
    ->getAll();
}