Code Duplication    Length = 8-9 lines in 3 locations

spec/Prophecy/Promise/CallbackPromiseSpec.php 3 locations

@@ 32-39 (lines=8) @@
29
        $this->execute(array('one', 'two'), $object, $method)->shouldReturn('one');
30
    }
31
32
    function it_should_execute_static_array_callback(ObjectProphecy $object, MethodProphecy $method)
33
    {
34
        $firstArgumentCallback = array('spec\Prophecy\Promise\ClassCallback', 'staticCallbackMethod');
35
36
        $this->beConstructedWith($firstArgumentCallback);
37
38
        $this->execute(array('one', 'two'), $object, $method)->shouldReturn('one');
39
    }
40
41
    function it_should_execute_instance_array_callback(ObjectProphecy $object, MethodProphecy $method)
42
    {
@@ 41-49 (lines=9) @@
38
        $this->execute(array('one', 'two'), $object, $method)->shouldReturn('one');
39
    }
40
41
    function it_should_execute_instance_array_callback(ObjectProphecy $object, MethodProphecy $method)
42
    {
43
        $class = new ClassCallback();
44
        $firstArgumentCallback = array($class, 'callbackMethod');
45
46
        $this->beConstructedWith($firstArgumentCallback);
47
48
        $this->execute(array('one', 'two'), $object, $method)->shouldReturn('one');
49
    }
50
51
    function it_should_execute_string_function_callback(ObjectProphecy $object, MethodProphecy $method)
52
    {
@@ 51-58 (lines=8) @@
48
        $this->execute(array('one', 'two'), $object, $method)->shouldReturn('one');
49
    }
50
51
    function it_should_execute_string_function_callback(ObjectProphecy $object, MethodProphecy $method)
52
    {
53
        $firstArgumentCallback = 'spec\Prophecy\Promise\functionCallbackFirstArgument';
54
55
        $this->beConstructedWith($firstArgumentCallback);
56
57
        $this->execute(array('one', 'two'), $object, $method)->shouldReturn('one');
58
    }
59
60
}
61