diff --git a/Delegation/JuniorDeveloper.php b/Delegation/JuniorDeveloper.php index e089162..ca80033 100644 --- a/Delegation/JuniorDeveloper.php +++ b/Delegation/JuniorDeveloper.php @@ -6,9 +6,10 @@ namespace DesignPatterns\Delegation; * Class JuniorDeveloper * @package DesignPatterns\Delegation */ -class JuniorDeveloper { - public function writeBadCode() - { - return "Some junior developer generated code..."; - } +class JuniorDeveloper +{ + public function writeBadCode() + { + return "Some junior developer generated code..."; + } } diff --git a/Delegation/TeamLead.php b/Delegation/TeamLead.php index 7407f58..f5ba323 100644 --- a/Delegation/TeamLead.php +++ b/Delegation/TeamLead.php @@ -9,24 +9,24 @@ namespace DesignPatterns\Delegation; */ class TeamLead { - /** @var JuniorDeveloper */ - protected $slave; + /** @var JuniorDeveloper */ + protected $slave; - /** - * Give junior developer into teamlead submission - * @param JuniorDeveloper $junior - */ - public function __construct(JuniorDeveloper $junior) - { - $this->slave = $junior; - } + /** + * Give junior developer into teamlead submission + * @param JuniorDeveloper $junior + */ + public function __construct(JuniorDeveloper $junior) + { + $this->slave = $junior; + } - /** - * TeamLead drink coffee, junior work - * @return mixed - */ - public function writeCode() - { - return $this->slave->writeBadCode(); - } + /** + * TeamLead drink coffee, junior work + * @return mixed + */ + public function writeCode() + { + return $this->slave->writeBadCode(); + } } diff --git a/Tests/Delegation/DelegationTest.php b/Tests/Delegation/DelegationTest.php index 1c88098..f9265a7 100644 --- a/Tests/Delegation/DelegationTest.php +++ b/Tests/Delegation/DelegationTest.php @@ -9,10 +9,10 @@ use DesignPatterns\Delegation; */ class DelegationTest extends \PHPUnit_Framework_TestCase { - public function testHowTeamLeadWriteCode() - { + public function testHowTeamLeadWriteCode() + { $junior = new Delegation\JuniorDeveloper(); - $teamLead = new Delegation\TeamLead($junior); - $this->assertEquals($junior->writeBadCode(), $teamLead->writeCode()); - } + $teamLead = new Delegation\TeamLead($junior); + $this->assertEquals($junior->writeBadCode(), $teamLead->writeCode()); + } }