protected function UnitTestCase::assertArrayEquals in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/tests/Drupal/Tests/UnitTestCase.php \Drupal\Tests\UnitTestCase::assertArrayEquals()
Asserts if two arrays are equal by sorting them first.
Parameters
array $expected:
array $actual:
string $message:
18 calls to UnitTestCase::assertArrayEquals()
- AttributeTest::testAddClasses in core/
tests/ Drupal/ Tests/ Core/ Template/ AttributeTest.php - Tests adding class attributes with the AttributeArray helper method. @covers ::addClass
- AttributeTest::testChainAddRemoveClasses in core/
tests/ Drupal/ Tests/ Core/ Template/ AttributeTest.php - Tests removing class attributes with the Attribute helper methods. @covers ::removeClass @covers ::addClass
- AttributeTest::testRemoveClasses in core/
tests/ Drupal/ Tests/ Core/ Template/ AttributeTest.php - Tests removing class attributes with the AttributeArray helper method. @covers ::removeClass
- AttributeTest::testSetAttribute in core/
tests/ Drupal/ Tests/ Core/ Template/ AttributeTest.php - Tests setting attributes. @covers ::setAttribute
- ContentEntityBaseUnitTest::testGetFields in core/
tests/ Drupal/ Tests/ Core/ Entity/ ContentEntityBaseUnitTest.php - @covers ::getFields @dataProvider providerGetFields
File
- core/
tests/ Drupal/ Tests/ UnitTestCase.php, line 90 - Contains \Drupal\Tests\UnitTestCase.
Class
- UnitTestCase
- Provides a base class and helpers for Drupal unit tests.
Namespace
Drupal\TestsCode
protected function assertArrayEquals(array $expected, array $actual, $message = NULL) {
ksort($expected);
ksort($actual);
$this
->assertEquals($expected, $actual, $message);
}