Passed
Push — master ( c70df2...3b77f2 )
by Caen
03:41 queued 11s
created

HydeHelperFacadeTest   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 8
dl 0
loc 21
rs 10
c 0
b 0
f 0
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A test_features_facade_can_be_used_to_call_static_methods_on_features_class() 0 4 1
A test_features_facade_returns_instance_of_features_class() 0 5 1
A test_hyde_has_feature_shorthand_calls_static_method_on_features_class() 0 4 1
1
<?php
2
3
namespace Hyde\Framework\Testing\Unit;
4
5
use Hyde\Framework\Helpers\Features;
6
use Hyde\Framework\Hyde;
7
use Hyde\Testing\TestCase;
8
9
/**
10
 * @covers \Hyde\Framework\HydeKernel
11
 */
12
class HydeHelperFacadeTest extends TestCase
13
{
14
    public function test_features_facade_returns_instance_of_features_class()
15
    {
16
        $this->assertInstanceOf(
17
            Features::class,
18
            Hyde::features()
19
        );
20
    }
21
22
    public function test_features_facade_can_be_used_to_call_static_methods_on_features_class()
23
    {
24
        $this->assertTrue(
25
            Hyde::features()->hasBlogPosts()
26
        );
27
    }
28
29
    public function test_hyde_has_feature_shorthand_calls_static_method_on_features_class()
30
    {
31
        $this->assertTrue(
32
            Hyde::hasFeature('blog-posts')
33
        );
34
    }
35
}
36