You are here

private function DomainListBuilderTest::getPaginatedDomains in Domain Access 8

Returns an array of domains, paginated and sorted by weight.

Parameters

int $page: The page number to return.

1 call to DomainListBuilderTest::getPaginatedDomains()
DomainListBuilderTest::testDomainListBuilder in domain/tests/src/Functional/DomainListBuilderTest.php
Basic test setup.

File

domain/tests/src/Functional/DomainListBuilderTest.php, line 189

Class

DomainListBuilderTest
Tests behavior for the domain list builder.

Namespace

Drupal\Tests\domain\Functional

Code

private function getPaginatedDomains($page = 0) {
  $limit = 50;
  $offset = $page * $limit;
  return array_slice($this
    ->getDomainsSorted(), $offset, $limit);
}