1 views_handler_filter_equality.test ViewsHandlerFilterEqualityTest::testNotEqual()

File

core/modules/views/tests/handlers/views_handler_filter_equality.test, line 75
Definition of ViewsHandlerFilterEqualityTest.

Class

ViewsHandlerFilterEqualityTest
Tests the core views_handler_filter_equality handler.

Code

function testNotEqual() {
  $view = $this->getBasicView();

  // Change the filtering
  $view->display['default']->handler->override_option('filters', array(
    'name' => array(
      'id' => 'name',
      'table' => 'views_test',
      'field' => 'name',
      'relationship' => 'none',
      'operator' => '!=',
      'value' => array('value' => 'Ringo'),
    ),
  ));

  $this->executeView($view);
  $resultset = array(
    array(
      'name' => 'John',
    ),
    array(
      'name' => 'George',
    ),
    array(
      'name' => 'Paul',
    ),
    array(
      'name' => 'Meredith',
    ),
  );
  $this->assertIdenticalResultset($view, $resultset, $this->column_map);
}