GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Pull Request — master (#6)
by Cees-Jan
25:20 queued 15:24
created
src/Type/String_.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ApiClients\Tools\ResourceTestUtilities\Type;
4 4
 
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
     public function generate(int $count = 10000): Generator
17 17
     {
18 18
         for ($i = 0; $i < $count; $i++) {
19
-            yield (string)mt_rand($i, $count * mt_rand($i, $count));
19
+            yield (string) mt_rand($i, $count * mt_rand($i, $count));
20 20
         }
21 21
     }
22 22
 
Please login to merge, or discard this patch.
src/Type/Int_.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ApiClients\Tools\ResourceTestUtilities\Type;
4 4
 
Please login to merge, or discard this patch.
src/Type.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ApiClients\Tools\ResourceTestUtilities\Type;
4 4
 
Please login to merge, or discard this patch.
src/TestCase.php 2 patches
Doc Comments   +7 added lines patch added patch discarded remove patch
@@ -34,6 +34,9 @@  discard block
 block discarded – undo
34 34
         $this->rmdir($this->tmpDir);
35 35
     }
36 36
 
37
+    /**
38
+     * @param string $dir
39
+     */
37 40
     protected function rmdir($dir)
38 41
     {
39 42
         $directory = dir($dir);
@@ -66,6 +69,10 @@  discard block
 block discarded – undo
66 69
         return $this->tmpNamespace;
67 70
     }
68 71
 
72
+    /**
73
+     * @param string $class
74
+     * @param string $namespace
75
+     */
69 76
     public function hydrate($class, $json, $namespace)
70 77
     {
71 78
         return (new Hydrator(Phake::mock(Client::class), [
Please login to merge, or discard this patch.
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1 1
 <?php
2
-declare(strict_types=1);
2
+declare(strict_types = 1);
3 3
 
4 4
 namespace ApiClients\Tools\ResourceTestUtilities;
5 5
 
@@ -23,9 +23,9 @@  discard block
 block discarded – undo
23 23
     public function setUp()
24 24
     {
25 25
         parent::setUp();
26
-        $this->tmpDir = sys_get_temp_dir() . DIRECTORY_SEPARATOR . uniqid('api-clients-tests-') . DIRECTORY_SEPARATOR;
26
+        $this->tmpDir = sys_get_temp_dir().DIRECTORY_SEPARATOR.uniqid('api-clients-tests-').DIRECTORY_SEPARATOR;
27 27
         mkdir($this->tmpDir, 0777, true);
28
-        $this->tmpNamespace = Configuration::DEFAULT_GENERATED_CLASS_NAMESPACE . uniqid('ApiClientsTestNamespace');
28
+        $this->tmpNamespace = Configuration::DEFAULT_GENERATED_CLASS_NAMESPACE.uniqid('ApiClientsTestNamespace');
29 29
     }
30 30
 
31 31
     public function tearDown()
@@ -42,13 +42,13 @@  discard block
 block discarded – undo
42 42
                 continue;
43 43
             }
44 44
 
45
-            if (is_dir($dir . $entry)) {
46
-                $this->rmdir($dir . $entry . DIRECTORY_SEPARATOR);
45
+            if (is_dir($dir.$entry)) {
46
+                $this->rmdir($dir.$entry.DIRECTORY_SEPARATOR);
47 47
                 continue;
48 48
             }
49 49
 
50
-            if (is_file($dir . $entry)) {
51
-                unlink($dir . $entry);
50
+            if (is_file($dir.$entry)) {
51
+                unlink($dir.$entry);
52 52
                 continue;
53 53
             }
54 54
         }
Please login to merge, or discard this patch.
src/AbstractResourceTest.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
1 1
 <?php
2
-declare(strict_types=1);
2
+declare(strict_types = 1);
3 3
 
4 4
 namespace ApiClients\Tools\ResourceTestUtilities;
5 5
 
@@ -65,15 +65,15 @@  discard block
 block discarded – undo
65 65
     {
66 66
         $json = $jsonTemplate;
67 67
         foreach ($type->$method as $typeClass) {
68
-            $methodType = Types::get(constant($typeClass . '::SCALAR'));
68
+            $methodType = Types::get(constant($typeClass.'::SCALAR'));
69 69
             foreach ($methodType->generate(25) as $value) {
70 70
                 $json[$property->getName()] = $value;
71 71
                 yield [
72 72
                     $property->getName(), // Name of the property to assign data to
73
-                    $method,              // Method to call verifying that data
74
-                    $type,                // The different types of data assiciated with this field
75
-                    $json,                // JSON to use during testing
76
-                    $value,               // Value to check against
73
+                    $method, // Method to call verifying that data
74
+                    $type, // The different types of data assiciated with this field
75
+                    $json, // JSON to use during testing
76
+                    $value, // Value to check against
77 77
                 ];
78 78
             }
79 79
         }
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
         $resource = $this->hydrate(
102 102
             str_replace(
103 103
                 $this->getNamespace(),
104
-                $this->getNamespace() . '\\Async',
104
+                $this->getNamespace().'\\Async',
105 105
                 $class
106 106
             ),
107 107
             $json,
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
         $resource = $this->hydrate(
122 122
             str_replace(
123 123
                 $this->getNamespace(),
124
-                $this->getNamespace() . '\\Async',
124
+                $this->getNamespace().'\\Async',
125 125
                 $class
126 126
             ),
127 127
             $json,
Please login to merge, or discard this patch.
src/Types.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ApiClients\Tools\ResourceTestUtilities;
4 4
 
@@ -27,17 +27,17 @@  discard block
 block discarded – undo
27 27
             return;
28 28
         }
29 29
 
30
-        $path = __DIR__ . DIRECTORY_SEPARATOR . 'Type' . DIRECTORY_SEPARATOR;
30
+        $path = __DIR__.DIRECTORY_SEPARATOR.'Type'.DIRECTORY_SEPARATOR;
31 31
         $directory = new RecursiveDirectoryIterator($path);
32 32
         $directory = new RecursiveIteratorIterator($directory);
33 33
         foreach ($directory as $node) {
34
-            $nodePath = $node->getPath() . DIRECTORY_SEPARATOR . $node->getFilename();
34
+            $nodePath = $node->getPath().DIRECTORY_SEPARATOR.$node->getFilename();
35 35
             if (!is_file($nodePath)) {
36 36
                 continue;
37 37
             }
38 38
 
39 39
             $fileName = str_replace('/', '\\', $nodePath);
40
-            $class = __NAMESPACE__ . '\\Type\\' . substr(substr($fileName, strlen($path)), 0, -4);
40
+            $class = __NAMESPACE__.'\\Type\\'.substr(substr($fileName, strlen($path)), 0, -4);
41 41
             if (class_exists($class) && (new ReflectionClass($class))->implementsInterface(Type::class)) {
42 42
                 $type = new $class;
43 43
                 self::$types[$type->scalar()] = $type;
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
             return self::$types[$type];
73 73
         }
74 74
 
75
-        throw new Exception('Type "' . $type . '" not found, use has to check"');
75
+        throw new Exception('Type "'.$type.'" not found, use has to check"');
76 76
     }
77 77
 
78 78
     /**
Please login to merge, or discard this patch.
src/Type/AbstractType.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@  discard block
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ApiClients\Tools\ResourceTestUtilities\Type;
4 4
 
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
     final public function __construct()
11 11
     {
12 12
         if (!defined('static::SCALAR')) {
13
-            throw new \InvalidArgumentException('Missing SCALAR constant on ' . get_class($this));
13
+            throw new \InvalidArgumentException('Missing SCALAR constant on '.get_class($this));
14 14
         }
15 15
     }
16 16
 
Please login to merge, or discard this patch.
src/Type/Double_.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ApiClients\Tools\ResourceTestUtilities\Type;
4 4
 
Please login to merge, or discard this patch.
src/Type/Float_.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,4 @@
 block discarded – undo
1
-<?php declare(strict_types=1);
1
+<?php declare(strict_types = 1);
2 2
 
3 3
 namespace ApiClients\Tools\ResourceTestUtilities\Type;
4 4
 
Please login to merge, or discard this patch.