getRows() public method

The output text for the item
public getRows ( MenuStyle $style, boolean $selected = false ) : array
$style PhpSchool\CliMenu\MenuStyle
$selected boolean
return array
Example #1
0
 public function testGetRowsWithMultiByteChars()
 {
     $menuStyle = $this->getMockBuilder(MenuStyle::class)->disableOriginalConstructor()->getMock();
     $menuStyle->expects($this->any())->method('getContentWidth')->will($this->returnValue(5));
     $item = new LineBreakItem('❅', 2);
     $this->assertEquals(['❅❅❅❅❅', '❅❅❅❅❅'], $item->getRows($menuStyle));
 }