Completed
Push — 2.0 ( f3c215...8251a6 )
by Nicolas
03:40
created

ThemeTest::setUp()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 3
nc 1
nop 0
dl 0
loc 6
rs 9.4285
c 0
b 0
f 0
1
<?php namespace Modules\Core\Tests\Theme;
2
3
use Modules\Core\Foundation\Theme\Theme;
4
use Modules\Core\Tests\BaseTestCase;
5
6
class ThemeTest extends BaseTestCase
7
{
8
    /**
9
     * @var \Modules\Core\Foundation\Theme\Theme
10
     */
11
    protected $theme;
12
13
    public function setUp()
14
    {
15
        parent::setUp();
16
17
        $this->theme = new Theme('demo', $this->getPath());
18
    }
19
20
    /** @test */
21
    public function it_should_return_name()
22
    {
23
        $this->assertEquals('Demo', $this->theme->getName());
24
    }
25
26
    /** @test */
27
    public function it_should_return_name_in_lowercase()
28
    {
29
        $this->assertEquals('demo', $this->theme->getLowerName());
30
    }
31
32
    /** @test */
33
    public function it_should_return_correct_path()
34
    {
35
        $this->assertEquals($this->getPath(), $this->theme->getPath());
36
    }
37
38
    private function getPath()
39
    {
40
        return __DIR__ . '/Fixture/Themes/demo';
41
    }
42
}
43