Skip to content
This repository has been archived by the owner on Jan 31, 2020. It is now read-only.

Commit

Permalink
Merge pull request zendframework/zendframework#2851 branch 'hotfix/ad…
Browse files Browse the repository at this point in the history
…d-blank-decorator-as-invokable'
  • Loading branch information
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/Table/DecoratorManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ class DecoratorManager extends AbstractPluginManager
*/
protected $invokableClasses = array(
'ascii' => 'Zend\Text\Table\Decorator\Ascii',
'blank' => 'Zend\Text\Table\Decorator\Blank',
'unicode' => 'Zend\Text\Table\Decorator\Unicode',
);

Expand Down
20 changes: 20 additions & 0 deletions test/TableTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -423,4 +423,24 @@ public function testDecoratorAscii()

$this->assertEquals($chars, '+++-++++|++');
}

public function testDecoratorBlank()
{
$decoratorManager = new Table\DecoratorManager;
$decorator = $decoratorManager->get('blank');

$chars = $decorator->getBottomLeft()
. $decorator->getBottomRight()
. $decorator->getCross()
. $decorator->getHorizontal()
. $decorator->getHorizontalDown()
. $decorator->getHorizontalUp()
. $decorator->getTopLeft()
. $decorator->getTopRight()
. $decorator->getVertical()
. $decorator->getVerticalLeft()
. $decorator->getVerticalRight();

$this->assertEquals($chars, '');
}
}

0 comments on commit c194c76

Please sign in to comment.