You are here

public function DomainPathTestBase::domainPathTableIsEmpty in Domain Path 8

Reusable test function for checking initial / empty table status.

1 call to DomainPathTestBase::domainPathTableIsEmpty()
DomainPathCreateTest::testDomainPathCreate in tests/src/Functional/DomainPathCreateTest.php
Tests initial domain path creation.

File

tests/src/Functional/DomainPathTestBase.php, line 83

Class

DomainPathTestBase

Namespace

Drupal\Tests\domain_path\Functional

Code

public function domainPathTableIsEmpty() {
  $domain_path_storage = \Drupal::service('entity_type.manager')
    ->getStorage('domain_path');
  $domain_paths = $domain_path_storage
    ->loadMultiple();
  $this
    ->assertTrue(empty($domain_paths), 'No domain paths have been created.');
}