ViewResultAssertionTrait
trait ViewResultAssertionTrait (View source)
Provides a class for assertions to check for the expected result of a View.
Methods
Verifies that a result set returned by a View matches expected values.
Verifies that a result set returned by a View differs from certain values.
Performs View result assertions.
Details
protected bool
assertIdenticalResultset(ViewExecutable $view, array $expected_result, array $column_map = [], string $message = NULL)
Verifies that a result set returned by a View matches expected values.
The comparison is done on the string representation of the columns of the column map, taking the order of the rows into account, but not the order of the columns.
protected bool
assertNotIdenticalResultset(ViewExecutable $view, array $expected_result, array $column_map = [], string $message = NULL)
Verifies that a result set returned by a View differs from certain values.
Inverse of ViewsTestCase::assertIdenticalResultset().
protected bool
assertIdenticalResultsetHelper(ViewExecutable $view, array $expected_result, array $column_map, string $assert_method, string $message = NULL)
Performs View result assertions.
This is a helper method for ViewTestBase::assertIdenticalResultset() and ViewTestBase::assertNotIdenticalResultset().