You are here

public function RabbitHoleBehaviorInvocationTestBase::testEntityDefaults in Rabbit Hole 8

Same name and namespace in other branches
  1. 2.x tests/src/Functional/RabbitHoleBehaviorInvocationTestBase.php \Drupal\Tests\rabbit_hole\Functional\RabbitHoleBehaviorInvocationTestBase::testEntityDefaults()

Test that a fresh entity with a fresh bundle takes the default action.

File

tests/src/Functional/RabbitHoleBehaviorInvocationTestBase.php, line 41

Class

RabbitHoleBehaviorInvocationTestBase
Base class for the rabbit hole behaviors invocation tests.

Namespace

Drupal\Tests\rabbit_hole\Functional

Code

public function testEntityDefaults() {
  $this
    ->createEntityBundle();
  $entity = $this
    ->createEntity();
  $this
    ->drupalGet($entity
    ->toUrl()
    ->toString());
  $this
    ->assertSession()
    ->statusCodeEquals(200);
}