Files
DesignPatternsPHP/More/Delegation/DelegationTest.php
2014-04-16 18:12:52 -03:00

19 lines
446 B
PHP

<?php
namespace DesignPatterns\More\Delegation;
use DesignPatterns\More\Delegation;
/**
* DelegationTest tests the delegation pattern
*/
class DelegationTest extends \PHPUnit_Framework_TestCase
{
public function testHowTeamLeadWriteCode()
{
$junior = new Delegation\JuniorDeveloper();
$teamLead = new Delegation\TeamLead($junior);
$this->assertEquals($junior->writeBadCode(), $teamLead->writeCode());
}
}