Completed
Pull Request — master (#141)
by Bhanu
37:51 queued 34s
created
phpspec/phpspec/spec/PhpSpec/Wrapper/Subject/Expectation/NegativeSpec.php 1 patch
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -4,8 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use PhpSpec\ObjectBehavior;
6 6
 use PhpSpec\Wrapper\Subject;
7
-use Prophecy\Argument;
8
-
9 7
 use PhpSpec\Matcher\MatcherInterface;
10 8
 
11 9
 class NegativeSpec extends ObjectBehavior
Please login to merge, or discard this patch.
phpspec/phpspec/spec/PhpSpec/Wrapper/Subject/Expectation/PositiveSpec.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use PhpSpec\Matcher\MatcherInterface;
6 6
 use PhpSpec\ObjectBehavior;
7
-use Prophecy\Argument;
8 7
 
9 8
 class PositiveSpec extends ObjectBehavior
10 9
 {
Please login to merge, or discard this patch.
phpspec/phpspec/spec/PhpSpec/Wrapper/Subject/ExpectationFactorySpec.php 1 patch
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,6 @@
 block discarded – undo
6 6
 use PhpSpec\ObjectBehavior;
7 7
 use PhpSpec\Wrapper\Subject;
8 8
 use Prophecy\Argument;
9
-
10 9
 use PhpSpec\Loader\Node\ExampleNode;
11 10
 use Symfony\Component\EventDispatcher\EventDispatcherInterface;
12 11
 use PhpSpec\Runner\MatcherManager;
Please login to merge, or discard this patch.
vendor/phpspec/phpspec/spec/PhpSpec/Wrapper/Subject/WrappedObjectSpec.php 2 patches
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -4,8 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use PhpSpec\Exception\Fracture\FactoryDoesNotReturnObjectException;
6 6
 use PhpSpec\ObjectBehavior;
7
-use Prophecy\Argument;
8
-
9 7
 use PhpSpec\Formatter\Presenter\PresenterInterface;
10 8
 
11 9
 class WrappedObjectSpec extends ObjectBehavior
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -74,10 +74,10 @@  discard block
 block discarded – undo
74 74
     {
75 75
         $this->callOnWrappedObject('beAnInstanceOf', array('\DateTime'));
76 76
 
77
-        $this->callOnWrappedObject('beConstructedThrough', array('createFromFormat',array('d-m-Y', '01-01-1980')));
77
+        $this->callOnWrappedObject('beConstructedThrough', array('createFromFormat', array('d-m-Y', '01-01-1980')));
78 78
         $this->callOnWrappedObject('instantiate', array());
79 79
         $this->shouldThrow('PhpSpec\Exception\Wrapper\SubjectException')
80
-            ->duringBeConstructedThrough(array('createFromFormat',array('d-m-Y', '01-01-1970')));
80
+            ->duringBeConstructedThrough(array('createFromFormat', array('d-m-Y', '01-01-1970')));
81 81
     }
82 82
 
83 83
     function it_throws_an_exception_when_trying_to_change_from_constructor_to_factory_method_after_instantiation()
@@ -87,14 +87,14 @@  discard block
 block discarded – undo
87 87
         $this->callOnWrappedObject('beConstructedWith', array(array('now')));
88 88
         $this->callOnWrappedObject('instantiate', array());
89 89
         $this->shouldThrow('PhpSpec\Exception\Wrapper\SubjectException')
90
-            ->duringBeConstructedThrough(array('createFromFormat',array('d-m-Y', '01-01-1970')));
90
+            ->duringBeConstructedThrough(array('createFromFormat', array('d-m-Y', '01-01-1970')));
91 91
     }
92 92
 
93 93
     function it_throws_an_exception_when_trying_to_change_from_factory_method_to_constructor_after_instantiation()
94 94
     {
95 95
         $this->callOnWrappedObject('beAnInstanceOf', array('\DateTime'));
96 96
 
97
-        $this->callOnWrappedObject('beConstructedThrough', array('createFromFormat',array('d-m-Y', '01-01-1980')));
97
+        $this->callOnWrappedObject('beConstructedThrough', array('createFromFormat', array('d-m-Y', '01-01-1980')));
98 98
         $this->callOnWrappedObject('instantiate', array());
99 99
         $this->shouldThrow('PhpSpec\Exception\Wrapper\SubjectException')->duringBeConstructedWith('tomorrow');
100 100
     }
Please login to merge, or discard this patch.
vendor/phpspec/phpspec/spec/PhpSpec/Wrapper/SubjectSpec.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,6 @@
 block discarded – undo
5 5
 use Phpspec\CodeAnalysis\AccessInspectorInterface;
6 6
 use PhpSpec\ObjectBehavior;
7 7
 use Prophecy\Argument;
8
-
9 8
 use PhpSpec\Wrapper\Wrapper;
10 9
 use PhpSpec\Wrapper\Subject\WrappedObject;
11 10
 use PhpSpec\Wrapper\Subject\Caller;
Please login to merge, or discard this patch.
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
 class SubjectSpec extends ObjectBehavior
17 17
 {
18 18
     function let(Wrapper $wrapper, WrappedObject $wrappedObject, Caller $caller, SubjectWithArrayAccess $arrayAccess,
19
-                 ExpectationFactory $expectationFactory, AccessInspectorInterface $accessInspector)
19
+                    ExpectationFactory $expectationFactory, AccessInspectorInterface $accessInspector)
20 20
     {
21 21
         $this->beConstructedWith(
22 22
             null,
Please login to merge, or discard this patch.
vendor/phpspec/phpspec/src/PhpSpec/Loader/StreamWrapper.php 2 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -38,6 +38,9 @@
 block discarded – undo
38 38
         static::$specTransformers[] = $specTransformer;
39 39
     }
40 40
 
41
+    /**
42
+     * @return string
43
+     */
41 44
     public static function wrapPath($path)
42 45
     {
43 46
         if (!defined('HHVM_VERSION'))
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -42,7 +42,7 @@
 block discarded – undo
42 42
     {
43 43
         if (!defined('HHVM_VERSION'))
44 44
         {
45
-            return 'phpspec://' . $path;
45
+            return 'phpspec://'.$path;
46 46
         }
47 47
 
48 48
         return $path;
Please login to merge, or discard this patch.
vendor/phpspec/phpspec/src/PhpSpec/Matcher/ScalarMatcher.php 1 patch
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
      * @param array  $arguments
56 56
      *
57 57
      * @throws \PhpSpec\Exception\Example\FailureException
58
-     * @return boolean
58
+     * @return boolean|null
59 59
      */
60 60
     public function positiveMatch($name, $subject, array $arguments)
61 61
     {
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
      * @param array  $arguments
83 83
      *
84 84
      * @throws \PhpSpec\Exception\Example\FailureException
85
-     * @return boolean
85
+     * @return boolean|null
86 86
      */
87 87
     public function negativeMatch($name, $subject, array $arguments)
88 88
     {
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
     /**
115 115
      * @param string $name
116 116
      *
117
-     * @return string|boolean
117
+     * @return false|string
118 118
      */
119 119
     private function getCheckerName($name)
120 120
     {
Please login to merge, or discard this patch.
vendor/phpspec/phpspec/src/PhpSpec/ObjectBehavior.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@
 block discarded – undo
72 72
     /**
73 73
      * Gets the unwrapped proxied object from PhpSpec subject
74 74
      *
75
-     * @return object
75
+     * @return \Prophecy\Prophecy\ObjectProphecy
76 76
      */
77 77
     public function getWrappedObject()
78 78
     {
Please login to merge, or discard this patch.
phpspec/phpspec/src/PhpSpec/Runner/Maintainer/CollaboratorsMaintainer.php 3 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -15,7 +15,6 @@
 block discarded – undo
15 15
 
16 16
 use PhpSpec\CodeAnalysis\DisallowedScalarTypehintException;
17 17
 use PhpSpec\Exception\Fracture\CollaboratorNotFoundException;
18
-use PhpSpec\Exception\Wrapper\CollaboratorException;
19 18
 use PhpSpec\Exception\Wrapper\InvalidCollaboratorTypeException;
20 19
 use PhpSpec\Loader\Node\ExampleNode;
21 20
 use PhpSpec\Loader\Transformer\InMemoryTypeHintIndex;
Please login to merge, or discard this patch.
Braces   +3 added lines, -6 removed lines patch added patch discarded remove patch
@@ -143,11 +143,9 @@  discard block
 block discarded – undo
143 143
                     || ($indexedClass = $this->getParameterTypeFromReflection($parameter))) {
144 144
                     $collaborator->beADoubleOf($indexedClass);
145 145
                 }
146
-            }
147
-            catch (ClassNotFoundException $e) {
146
+            } catch (ClassNotFoundException $e) {
148 147
                 $this->throwCollaboratorNotFound($e, null, $e->getClassname());
149
-            }
150
-            catch (DisallowedScalarTypehintException $e) {
148
+            } catch (DisallowedScalarTypehintException $e) {
151 149
                 throw new InvalidCollaboratorTypeException($parameter, $function);
152 150
             }
153 151
         }
@@ -218,8 +216,7 @@  discard block
 block discarded – undo
218 216
             }
219 217
 
220 218
             return $class->getName();
221
-        }
222
-        catch (ReflectionException $e) {
219
+        } catch (ReflectionException $e) {
223 220
             $this->throwCollaboratorNotFound($e, $parameter);
224 221
         }
225 222
     }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -201,7 +201,7 @@
 block discarded – undo
201 201
         return $this->typeHintIndex->lookup(
202 202
             $classRefl->getName(),
203 203
             $parameter->getDeclaringFunction()->getName(),
204
-            '$' . $parameter->getName()
204
+            '$'.$parameter->getName()
205 205
         );
206 206
     }
207 207
 
Please login to merge, or discard this patch.