Total Complexity | 3 |
Total Lines | 24 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
22 | class FactoryMethodTest extends PHPUnit_Framework_TestCase |
||
23 | { |
||
24 | |||
25 | /** |
||
26 | * @var FactoryMethod |
||
27 | */ |
||
28 | protected $factory; |
||
29 | |||
30 | protected function setUp(): void |
||
31 | { |
||
32 | $this->factory = new FactoryMethod(); |
||
33 | } |
||
34 | |||
35 | public function testProducts() |
||
36 | { |
||
37 | $this->assertEquals($this->factory->getProduct('FirstProduct')->getClassName(), FirstProduct::class); |
||
38 | $this->assertEquals($this->factory->getProduct('SecondProduct')->getClassName(), SecondProduct::class); |
||
39 | } |
||
40 | |||
41 | public function testFactoryMethod() |
||
46 | } |
||
47 | } |
||
48 |