ErrorObserversSpec   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 3
c 1
b 0
f 0
lcom 0
cbo 2
dl 0
loc 17
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A it_can_only_be_constructed_with_observers() 0 4 1
A it_can_be_constructed_with_observers() 0 4 1
A it_is_traversable() 0 4 1
1
<?php
2
3
namespace spec\RMiller\BehatSpec\Extension\ErrorExtension\Observer;
4
5
use PhpSpec\ObjectBehavior;
6
use Prophecy\Argument;
7
use RMiller\BehatSpec\Extension\ErrorExtension\Observer\ErrorObserver;
8
9
class ErrorObserversSpec extends ObjectBehavior
10
{
11
    function it_can_only_be_constructed_with_observers()
12
    {
13
        $this->shouldThrow('\InvalidArgumentException')->during('__construct', [[new \stdClass()]]);
14
    }
15
16
    function it_can_be_constructed_with_observers(ErrorObserver $observer)
17
    {
18
        $this->beConstructedWith([$observer]);
19
    }
20
21
    function it_is_traversable()
22
    {
23
        $this->shouldHaveType('\Traversable');
24
    }
25
}
26