public function StyleGridTest::testGrid in Drupal 8
Same name and namespace in other branches
- 9 core/modules/views/tests/src/Kernel/Plugin/StyleGridTest.php \Drupal\Tests\views\Kernel\Plugin\StyleGridTest::testGrid()
Tests the grid style.
File
- core/
modules/ views/ tests/ src/ Kernel/ Plugin/ StyleGridTest.php, line 33
Class
- StyleGridTest
- Tests the grid style plugin.
Namespace
Drupal\Tests\views\Kernel\PluginCode
public function testGrid() {
$view = Views::getView('test_grid');
foreach ([
'horizontal',
'vertical',
] as $alignment) {
$this
->assertGrid($view, $alignment, 5);
$this
->assertGrid($view, $alignment, 4);
$this
->assertGrid($view, $alignment, 3);
$this
->assertGrid($view, $alignment, 2);
$this
->assertGrid($view, $alignment, 1);
}
}