Source of file GridFieldGroupableTest.php
Size: 1,461 Bytes - Last Modified: 2021-12-23T10:04:43+00:00
/var/www/docs.ssmods.com/process/src/tests/GridFieldGroupableTest.php
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 | <?php namespace micschk\GroupableGridfield\Test; use micschk\GroupableGridfield\GridFieldGroupable; use SilverStripe\Dev\SapphireTest; use SilverStripe\ORM\DataObject; /** * Class GridFieldGroupableTest */ class GridFieldGroupableTest extends SapphireTest { /** * */ public function testGetURLHandlers() { $groupable = new GridFieldGroupable(); $this->assertInternalType('array', $groupable->getURLHandlers(null)); } /** * */ public function testGetColumnsHandled() { $groupable = new GridFieldGroupable(); $this->assertInternalType('array', $groupable->getColumnsHandled(null)); } /** * */ public function testGetColumnContent() { $groupable = new GridFieldGroupable(); $this->assertNull($groupable->getColumnContent(null, null, '')); } /** * */ public function testGetColumnAttributes() { $groupable = new GridFieldGroupable('ID'); $record = DataObject::create(); $attributes = $groupable->getColumnAttributes(null, $record, null); $this->assertInternalType('array', $attributes); $this->assertArrayHasKey('data-groupable-group', $attributes); } /** * */ public function testGetColumnMetadata() { $groupable = new GridFieldGroupable(); $this->assertInternalType('array', $groupable->getColumnMetadata(null,'')); } } |