You are here

protected function RouteSubscriberTest::setupRouteCollection in Replicate UI 8

2 calls to RouteSubscriberTest::setupRouteCollection()
RouteSubscriberTest::testDisabledReplicateFunctionality in tests/src/Unit/RouteSubscriberTest.php
@covers ::onRouteBuild
RouteSubscriberTest::testEnabledReplicateFunctionality in tests/src/Unit/RouteSubscriberTest.php
@covers ::onRouteBuild

File

tests/src/Unit/RouteSubscriberTest.php, line 84

Class

RouteSubscriberTest
@coversDefaultClass \Drupal\replicate_ui\RouteSubscriber @group replicate

Namespace

Drupal\Tests\replicate_ui\Unit

Code

protected function setupRouteCollection() {
  $route_collection = new RouteCollection();
  $route_collection
    ->add('entity.entity_test_1.canonical', new Route('/entity_test_1/{entity_test_1}'));
  $route_collection
    ->add('entity.entity_test_2.canonical', new Route('/entity_test_2/{entity_test_2}'));
  $route_collection
    ->add('entity.entity_test_1.edit_form', new Route('/entity_test_1/{entity_test_1}/edit'));
  $route_collection
    ->add('entity.entity_test_2.edit_form', new Route('/entity_test_2/{entity_test_2}/edit', [], [], [
    '_admin_route' => TRUE,
  ]));
  return $route_collection;
}