Passed
Push — master ( 57f60d...31b82d )
by Aleksei
12:30
created
src/Prototype/src/NodeVisitors/LocateProperties.php 2 patches
Braces   +8 added lines, -4 removed lines patch added patch discarded remove patch
@@ -43,9 +43,12 @@  discard block
 block discarded – undo
43 43
             $this->requested[$node->name->name] = $node->name->name;
44 44
         }
45 45
 
46
-        if ($node instanceof Node\Stmt\Property) {
47
-            foreach ($node->props as $prop) {
48
-                if ($prop instanceof Node\Stmt\PropertyProperty) {
46
+        if ($node instanceof Node\Stmt\Property)
47
+        {
48
+            foreach ($node->props as $prop)
49
+            {
50
+                if ($prop instanceof Node\Stmt\PropertyProperty)
51
+                {
49 52
                     $this->properties[$prop->name->name] = $prop->name->name;
50 53
                 }
51 54
             }
@@ -56,7 +59,8 @@  discard block
 block discarded – undo
56 59
 
57 60
     private function promotedProperties(Node $node): void
58 61
     {
59
-        if (!$node instanceof Node\Param || !$node->var instanceof Node\Expr\Variable) {
62
+        if (!$node instanceof Node\Param || !$node->var instanceof Node\Expr\Variable)
63
+        {
60 64
             return;
61 65
         }
62 66
 
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -38,13 +38,13 @@  discard block
 block discarded – undo
38 38
             $node->var instanceof Node\Expr\Variable &&
39 39
             $node->var->name === 'this' &&
40 40
             $node->name instanceof Node\Identifier
41
-        ) {
41
+        ){
42 42
             $this->requested[$node->name->name] = $node->name->name;
43 43
         }
44 44
 
45
-        if ($node instanceof Node\Stmt\Property) {
46
-            foreach ($node->props as $prop) {
47
-                if ($prop instanceof Node\Stmt\PropertyProperty) {
45
+        if ($node instanceof Node\Stmt\Property){
46
+            foreach ($node->props as $prop){
47
+                if ($prop instanceof Node\Stmt\PropertyProperty){
48 48
                     $this->properties[$prop->name->name] = $prop->name->name;
49 49
                 }
50 50
             }
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
 
56 56
     private function promotedProperties(Node $node): void
57 57
     {
58
-        if (!$node instanceof Node\Param || !$node->var instanceof Node\Expr\Variable) {
58
+        if (!$node instanceof Node\Param || !$node->var instanceof Node\Expr\Variable){
59 59
             return;
60 60
         }
61 61
 
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
             $node->flags & Node\Stmt\Class_::MODIFIER_PUBLIC ||
64 64
             $node->flags & Node\Stmt\Class_::MODIFIER_PROTECTED ||
65 65
             $node->flags & Node\Stmt\Class_::MODIFIER_PRIVATE
66
-        ) {
66
+        ){
67 67
             $this->properties[$node->var->name] = $node->var->name;
68 68
         }
69 69
     }
Please login to merge, or discard this patch.
src/Tokenizer/src/ScopedEnumsInterface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,5 +16,5 @@
 block discarded – undo
16 16
      *
17 17
      * @return \ReflectionEnum[]
18 18
      */
19
-    public function getScopedEnums(string $scope, object|string|null $target = null): array;
19
+    public function getScopedEnums(string $scope, object | string | null $target = null): array;
20 20
 }
Please login to merge, or discard this patch.
src/Tokenizer/src/Listener/ListenerInvoker.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
      */
17 17
     public function invoke(TokenizationListenerInterface $listener, iterable $classes): void
18 18
     {
19
-        foreach ($classes as $class) {
19
+        foreach ($classes as $class){
20 20
             $listener->listen($class);
21 21
         }
22 22
     }
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,8 @@
 block discarded – undo
16 16
      */
17 17
     public function invoke(TokenizationListenerInterface $listener, iterable $classes): void
18 18
     {
19
-        foreach ($classes as $class) {
19
+        foreach ($classes as $class)
20
+        {
20 21
             $listener->listen($class);
21 22
         }
22 23
     }
Please login to merge, or discard this patch.
src/Tokenizer/src/ScopedInterfacesInterface.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,5 +17,5 @@
 block discarded – undo
17 17
      *                            results.
18 18
      * @return \ReflectionClass[]
19 19
      */
20
-    public function getScopedInterfaces(string $scope, string|null $target = null): array;
20
+    public function getScopedInterfaces(string $scope, string | null $target = null): array;
21 21
 }
Please login to merge, or discard this patch.
src/Tokenizer/src/Listener/CachedInterfacesLoader.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
         private readonly InterfaceLocatorByTarget $locator,
19 19
         ListenerInvoker $invoker,
20 20
         bool $readCache = true,
21
-    ) {
21
+    ){
22 22
         parent::__construct($reader, $memory, $invoker, $readCache);
23 23
     }
24 24
 
Please login to merge, or discard this patch.
src/Tokenizer/src/Listener/CachedEnumsLoader.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -18,7 +18,7 @@
 block discarded – undo
18 18
         private readonly EnumLocatorByTarget $locator,
19 19
         ListenerInvoker $invoker,
20 20
         bool $readCache = true,
21
-    ) {
21
+    ){
22 22
         parent::__construct($reader, $memory, $invoker, $readCache);
23 23
     }
24 24
 
Please login to merge, or discard this patch.
src/Tokenizer/src/Listener/CachedClassesLoader.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@
 block discarded – undo
16 16
         private readonly ClassLocatorByTarget $locator,
17 17
         ListenerInvoker $invoker,
18 18
         bool $readCache = true,
19
-    ) {
19
+    ){
20 20
         parent::__construct($reader, $memory, $invoker, $readCache);
21 21
     }
22 22
 
Please login to merge, or discard this patch.
src/Tokenizer/tests/Listener/EnumLocatorByTargetTest.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -22,8 +22,8 @@  discard block
 block discarded – undo
22 22
     use MockeryPHPUnitIntegration;
23 23
 
24 24
     private EnumLocatorByTarget $locator;
25
-    private EnumsInterface|m\LegacyMockInterface|m\MockInterface $classes;
26
-    private ScopedEnumsInterface|m\LegacyMockInterface|m\MockInterface $scopedClasses;
25
+    private EnumsInterface | m\LegacyMockInterface | m\MockInterface $classes;
26
+    private ScopedEnumsInterface | m\LegacyMockInterface | m\MockInterface $scopedClasses;
27 27
 
28 28
     protected function setUp(): void
29 29
     {
@@ -79,11 +79,11 @@  discard block
 block discarded – undo
79 79
         $attr = $attr->getAttributes()[0];
80 80
         $attribute = $attr->newInstance();
81 81
 
82
-        if ($attribute->getScope() === null) {
82
+        if ($attribute->getScope() === null){
83 83
             $this->classes
84 84
                 ->shouldReceive('getEnums')
85 85
                 ->andReturn($enums);
86
-        } else {
86
+        }else{
87 87
             $this->scopedClasses
88 88
                 ->shouldReceive('getScopedEnums')
89 89
                 ->with($attribute->getScope())
Please login to merge, or discard this patch.
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -79,11 +79,14 @@
 block discarded – undo
79 79
         $attr = $attr->getAttributes()[0];
80 80
         $attribute = $attr->newInstance();
81 81
 
82
-        if ($attribute->getScope() === null) {
82
+        if ($attribute->getScope() === null)
83
+        {
83 84
             $this->classes
84 85
                 ->shouldReceive('getEnums')
85 86
                 ->andReturn($enums);
86
-        } else {
87
+        }
88
+        else
89
+        {
87 90
             $this->scopedClasses
88 91
                 ->shouldReceive('getScopedEnums')
89 92
                 ->with($attribute->getScope())
Please login to merge, or discard this patch.
src/Tokenizer/tests/Listener/InterfaceLocatorByTargetTest.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -25,8 +25,8 @@  discard block
 block discarded – undo
25 25
     use MockeryPHPUnitIntegration;
26 26
 
27 27
     private InterfaceLocatorByTarget $locator;
28
-    private InterfacesInterface|m\LegacyMockInterface|m\MockInterface $interfaces;
29
-    private ScopedInterfacesInterface|m\LegacyMockInterface|m\MockInterface $scopedInterfaces;
28
+    private InterfacesInterface | m\LegacyMockInterface | m\MockInterface $interfaces;
29
+    private ScopedInterfacesInterface | m\LegacyMockInterface | m\MockInterface $scopedInterfaces;
30 30
 
31 31
     protected function setUp(): void
32 32
     {
@@ -105,11 +105,11 @@  discard block
 block discarded – undo
105 105
         $attr = $attr->getAttributes()[0];
106 106
         $attribute = $attr->newInstance();
107 107
 
108
-        if ($attribute->getScope() === null) {
108
+        if ($attribute->getScope() === null){
109 109
             $this->interfaces
110 110
                 ->shouldReceive('getInterfaces')
111 111
                 ->andReturn($interfaces);
112
-        } else {
112
+        }else{
113 113
             $this->scopedInterfaces
114 114
                 ->shouldReceive('getScopedInterfaces')
115 115
                 ->with($attribute->getScope())
Please login to merge, or discard this patch.
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -105,11 +105,14 @@
 block discarded – undo
105 105
         $attr = $attr->getAttributes()[0];
106 106
         $attribute = $attr->newInstance();
107 107
 
108
-        if ($attribute->getScope() === null) {
108
+        if ($attribute->getScope() === null)
109
+        {
109 110
             $this->interfaces
110 111
                 ->shouldReceive('getInterfaces')
111 112
                 ->andReturn($interfaces);
112
-        } else {
113
+        }
114
+        else
115
+        {
113 116
             $this->scopedInterfaces
114 117
                 ->shouldReceive('getScopedInterfaces')
115 118
                 ->with($attribute->getScope())
Please login to merge, or discard this patch.