저자: Michael Woodward (mikeymike.mw@gmail.com)
상속: implements PhpSchool\CliMenu\MenuItem\MenuItemInterface
예제 #1
0
 public function testGetRowsCenterAlignedWithOddWidth()
 {
     $menuStyle = $this->getMockBuilder(MenuStyle::class)->disableOriginalConstructor()->getMock();
     $menuStyle->expects($this->any())->method('getContentWidth')->will($this->returnValue(11));
     $item = new AsciiArtItem("//\n//", AsciiArtItem::POSITION_CENTER);
     $this->assertEquals(["     //    ", "     //    "], $item->getRows($menuStyle));
 }