Skip to content

Commit

Permalink
Add tests for #6046
Browse files Browse the repository at this point in the history
  • Loading branch information
markstory committed Mar 11, 2015
1 parent 65bc143 commit c644474
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/TestCase/View/CellTest.php
Expand Up @@ -75,6 +75,10 @@ public function testCellRender()
$this->assertContains('<h2>Usectetur adipiscing eli</h2>', $render);
$this->assertContains('<h2>Topis semper blandit eu non</h2>', $render);
$this->assertContains('<h2>Suspendisse gravida neque</h2>', $render);

$cell = $this->View->cell('Cello');
$this->assertInstanceOf('TestApp\View\Cell\CelloCell', $cell);
$this->assertEquals("Cellos\n", $cell->render());
}

/**
Expand Down
1 change: 1 addition & 0 deletions tests/test_app/TestApp/Template/Cell/Cello/display.ctp
@@ -0,0 +1 @@
Cellos
26 changes: 26 additions & 0 deletions tests/test_app/TestApp/View/Cell/CelloCell.php
@@ -0,0 +1,26 @@
<?php
/**
* CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
* Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
*
* Licensed under The MIT License
* Redistributions of files must retain the above copyright notice.
*
* @copyright Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
* @link http://cakephp.org CakePHP(tm) Project
* @since 3.0.0
* @license http://www.opensource.org/licenses/mit-license.php MIT License
*/
namespace TestApp\View\Cell;

use Cake\View\Cell;

/**
* Class naming test stub.
*/
class CelloCell extends Cell
{
public function display()
{
}
}

0 comments on commit c644474

Please sign in to comment.