function ModuleTest::assertInstanceHandler

Ensure that a certain handler is a instance of a certain table/field.

1 call to ModuleTest::assertInstanceHandler()
ModuleTest::testViewsGetHandler in drupal/core/modules/views/lib/Drupal/views/Tests/ModuleTest.php
Tests the views_get_handler method.

File

drupal/core/modules/views/lib/Drupal/views/Tests/ModuleTest.php, line 285
Definition of Drupal\views\Tests\ModuleTest.

Class

ModuleTest

Namespace

Drupal\views\Tests

Code

function assertInstanceHandler($handler, $table, $field, $id) {
  $table_data = Views::viewsData()
    ->get($table);
  $field_data = $table_data[$field][$id];
  $this
    ->assertEqual($field_data['id'], $handler
    ->getPluginId());
}