You are here

public static function FieldLayoutEntityDisplayTest::assertEntityValues in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/field_layout/tests/src/Kernel/FieldLayoutEntityDisplayTest.php \Drupal\Tests\field_layout\Kernel\FieldLayoutEntityDisplayTest::assertEntityValues()

Asserts than an entity has the correct values.

Parameters

mixed $expected:

array $values:

string $message:

1 call to FieldLayoutEntityDisplayTest::assertEntityValues()
FieldLayoutEntityDisplayTest::testPreSave in core/modules/field_layout/tests/src/Kernel/FieldLayoutEntityDisplayTest.php
@covers ::preSave @covers ::calculateDependencies

File

core/modules/field_layout/tests/src/Kernel/FieldLayoutEntityDisplayTest.php, line 182

Class

FieldLayoutEntityDisplayTest
@coversDefaultClass \Drupal\field_layout\Entity\FieldLayoutEntityDisplayTrait @group field_layout

Namespace

Drupal\Tests\field_layout\Kernel

Code

public static function assertEntityValues($expected, array $values, $message = '') {
  static::assertArrayHasKey('uuid', $values);
  unset($values['uuid']);
  static::assertEquals($expected, $values, $message);
}