| 1 |
<?php |
| 2 |
|
| 3 |
use PHPUnit\Framework\TestCase; |
| 4 |
|
| 5 |
class ComponentFactoryTest extends TestCase { |
| 6 |
|
| 7 |
public function setUp() { |
| 8 |
$this->factory = new ResponsiveMenu\ViewModels\Components\ComponentFactory; |
| 9 |
} |
| 10 |
|
| 11 |
public function testMapTitle() { |
| 12 |
$this->assertInstanceOf('ResponsiveMenu\ViewModels\Components\Menu\Title', $this->factory->build('title')); |
| 13 |
} |
| 14 |
|
| 15 |
public function testMapMenu() { |
| 16 |
$this->assertInstanceOf('ResponsiveMenu\ViewModels\Components\Menu\Menu', $this->factory->build('menu')); |
| 17 |
} |
| 18 |
|
| 19 |
public function testMapSearch() { |
| 20 |
$this->assertInstanceOf('ResponsiveMenu\ViewModels\Components\Menu\Search', $this->factory->build('search')); |
| 21 |
} |
| 22 |
|
| 23 |
public function testMapAdditionalContent() { |
| 24 |
$this->assertInstanceOf('ResponsiveMenu\ViewModels\Components\Menu\AdditionalContent', $this->factory->build('additional content')); |
| 25 |
} |
| 26 |
|
| 27 |
} |
| 28 |
|