function ViewExecutableTest::testArgumentValidatorValueOverride
Tests if argument overrides by validators are propagated to tokens.
File
- 
              core/modules/ views/ tests/ src/ Kernel/ ViewExecutableTest.php, line 541 
Class
- ViewExecutableTest
- Tests the ViewExecutable class.
Namespace
Drupal\Tests\views\KernelCode
public function testArgumentValidatorValueOverride() {
  $view = Views::getView('test_argument_dependency');
  $view->setDisplay('page_1');
  $view->setArguments([
    '1',
    'this value should be replaced',
  ]);
  $view->execute();
  $expected = [
    '{{ arguments.uid }}' => '1',
    '{{ raw_arguments.uid }}' => '1',
  ];
  $this->assertEquals($expected, $view->build_info['substitutions']);
}Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.
