'id' => 'id', 'field_test' => 'field_test', 'user_id' => 'user_id'
] );
} /**
* Tests the output of a view with base fields and configurable fields.
*/
public function testSimpleRender() { $executable = Views::
getView('test_field_field_test'
);
$executable->
execute();
$this->
assertEquals('1',
$executable->
getStyle()->
getField(0, 'id'
));
$this->
assertEquals('3',
$executable->
getStyle()->
getField(0, 'field_test'
));
$this->
assertEquals('2',
$executable->
getStyle()->
getField(1, 'id'
));
// @todo Switch this assertion to assertSame('', ...) when
// https://www.drupal.org/node/2488006 gets fixed.
$this->
assertEquals('0',
$executable->
getStyle()->
getField(1, 'field_test'
));
$this->
assertEquals('3',
$executable->
getStyle()->
getField(2, 'id'
));
$this->
assertEquals('8',
$executable->
getStyle()->
getField(2, 'field_test'
));
$this->
assertEquals('4',
$executable->
getStyle()->
getField(3, 'id'
));
$this->
assertEquals('5',
$executable->
getStyle()->
getField(3, 'field_test'
));
$this->
assertEquals('5',
$executable->
getStyle()->
getField(4, 'id'
));
$this->
assertEquals('6',
$executable->
getStyle()->
getField(4, 'field_test'
));
}