Mercurial > hg > isophonics-drupal-site
comparison core/modules/views/tests/src/Kernel/ViewExecutableTest.php @ 16:c2387f117808
Routine composer update
author | Chris Cannam |
---|---|
date | Tue, 10 Jul 2018 15:07:59 +0100 |
parents | 4c8ae668cc8c |
children | 129ea1e6d783 |
comparison
equal
deleted
inserted
replaced
15:e200cb7efeb3 | 16:c2387f117808 |
---|---|
36 /** | 36 /** |
37 * Views used by this test. | 37 * Views used by this test. |
38 * | 38 * |
39 * @var array | 39 * @var array |
40 */ | 40 */ |
41 public static $testViews = ['test_destroy', 'test_executable_displays']; | 41 public static $testViews = ['test_destroy', 'test_executable_displays', 'test_argument_dependency']; |
42 | 42 |
43 /** | 43 /** |
44 * Properties that should be stored in the configuration. | 44 * Properties that should be stored in the configuration. |
45 * | 45 * |
46 * @var array | 46 * @var array |
523 ->getItemDefinition() | 523 ->getItemDefinition() |
524 ->getFieldDefinition(); | 524 ->getFieldDefinition(); |
525 $this->assertEquals($nid_definition_before->getPropertyDefinitions(), $nid_definition_after->getPropertyDefinitions()); | 525 $this->assertEquals($nid_definition_before->getPropertyDefinitions(), $nid_definition_after->getPropertyDefinitions()); |
526 } | 526 } |
527 | 527 |
528 /** | |
529 * Tests if argument overrides by validators are propagated to tokens. | |
530 */ | |
531 public function testArgumentValidatorValueOverride() { | |
532 $view = Views::getView('test_argument_dependency'); | |
533 $view->setDisplay('page_1'); | |
534 $view->setArguments(['1', 'this value should be replaced']); | |
535 $view->execute(); | |
536 $expected = [ | |
537 '{{ arguments.uid }}' => '1', | |
538 '{{ raw_arguments.uid }}' => '1', | |
539 ]; | |
540 $this->assertEquals($expected, $view->build_info['substitutions']); | |
541 } | |
542 | |
528 } | 543 } |