mirror of
https://github.com/DesignPatternsPHP/DesignPatternsPHP.git
synced 2025-08-07 07:26:32 +02:00
Applied fixes from StyleCI
This commit is contained in:
committed by
StyleCI Bot
parent
3663603b80
commit
fe1f144ec3
@@ -3,12 +3,12 @@
|
||||
namespace DesignPatterns\Behavioral\TemplateMethod;
|
||||
|
||||
/**
|
||||
* BeachJourney is vacation at the beach
|
||||
* BeachJourney is vacation at the beach.
|
||||
*/
|
||||
class BeachJourney extends Journey
|
||||
{
|
||||
/**
|
||||
* prints what to do to enjoy your vacation
|
||||
* prints what to do to enjoy your vacation.
|
||||
*/
|
||||
protected function enjoyVacation()
|
||||
{
|
||||
|
@@ -3,12 +3,12 @@
|
||||
namespace DesignPatterns\Behavioral\TemplateMethod;
|
||||
|
||||
/**
|
||||
* CityJourney is a journey in a city
|
||||
* CityJourney is a journey in a city.
|
||||
*/
|
||||
class CityJourney extends Journey
|
||||
{
|
||||
/**
|
||||
* prints what to do in your journey to enjoy vacation
|
||||
* prints what to do in your journey to enjoy vacation.
|
||||
*/
|
||||
protected function enjoyVacation()
|
||||
{
|
||||
|
@@ -23,7 +23,7 @@ abstract class Journey
|
||||
}
|
||||
|
||||
/**
|
||||
* This method must be implemented, this is the key-feature of this pattern
|
||||
* This method must be implemented, this is the key-feature of this pattern.
|
||||
*/
|
||||
abstract protected function enjoyVacation();
|
||||
|
||||
@@ -37,7 +37,7 @@ abstract class Journey
|
||||
}
|
||||
|
||||
/**
|
||||
* This method will be unknown by subclasses (better)
|
||||
* This method will be unknown by subclasses (better).
|
||||
*/
|
||||
private function buyAFlight()
|
||||
{
|
||||
@@ -46,7 +46,7 @@ abstract class Journey
|
||||
|
||||
/**
|
||||
* Subclasses will get access to this method but cannot override it and
|
||||
* compromise this algorithm (warning : cause of cyclic dependencies)
|
||||
* compromise this algorithm (warning : cause of cyclic dependencies).
|
||||
*/
|
||||
final protected function takePlane()
|
||||
{
|
||||
|
@@ -5,11 +5,10 @@ namespace DesignPatterns\Behavioral\TemplateMethod\Tests;
|
||||
use DesignPatterns\Behavioral\TemplateMethod;
|
||||
|
||||
/**
|
||||
* JourneyTest tests all journeys
|
||||
* JourneyTest tests all journeys.
|
||||
*/
|
||||
class JourneyTest extends \PHPUnit_Framework_TestCase
|
||||
{
|
||||
|
||||
public function testBeach()
|
||||
{
|
||||
$journey = new TemplateMethod\BeachJourney();
|
||||
@@ -25,7 +24,7 @@ class JourneyTest extends \PHPUnit_Framework_TestCase
|
||||
}
|
||||
|
||||
/**
|
||||
* How to test an abstract template method with PHPUnit
|
||||
* How to test an abstract template method with PHPUnit.
|
||||
*/
|
||||
public function testLasVegas()
|
||||
{
|
||||
|
Reference in New Issue
Block a user