Skip to content

Commit

Permalink
Added phpdoc to abstract test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
core23 committed Jul 24, 2016
1 parent 790d76b commit d3dbcef
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions Test/AbstractBlockServiceTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,13 @@ protected function setUp()
$this->blockContextManager = new BlockContextManager($blockLoader, $this->blockServiceManager);
}

/**
* Create a mocked block service.
*
* @param BlockServiceInterface $blockService A block service
*
* @return BlockContextInterface
*/
protected function getBlockContext(BlockServiceInterface $blockService)
{
$this->blockServiceManager->expects($this->once())->method('get')->will($this->returnValue($blockService));
Expand All @@ -68,6 +75,12 @@ protected function getBlockContext(BlockServiceInterface $blockService)
return $blockContext;
}

/**
* Asserts that the block settings have the expected values.
*
* @param array $expected Expected settings
* @param BlockContextInterface $blockContext BlockContext object
*/
protected function assertSettings(array $expected, BlockContextInterface $blockContext)
{
$completeExpectedOptions = array_merge(array(
Expand Down

0 comments on commit d3dbcef

Please sign in to comment.