Passed
Push — master ( ff614d...6c840c )
by Anton
05:03 queued 02:24
created
tests/Framework/SnapshotTest.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,9 +17,9 @@
 block discarded – undo
17 17
     {
18 18
         $app = $this->makeApp();
19 19
 
20
-        try {
20
+        try{
21 21
             throw new \Error("test error");
22
-        } catch (\Error $e) {
22
+        }catch (\Error $e){
23 23
             /** @var SnapshotInterface $s */
24 24
             $s = $app->get(SnapshotterInterface::class)->register($e);
25 25
         }
Please login to merge, or discard this patch.
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,9 +17,12 @@
 block discarded – undo
17 17
     {
18 18
         $app = $this->makeApp();
19 19
 
20
-        try {
20
+        try
21
+        {
21 22
             throw new \Error("test error");
22
-        } catch (\Error $e) {
23
+        }
24
+        catch (\Error $e)
25
+        {
23 26
             /** @var SnapshotInterface $s */
24 27
             $s = $app->get(SnapshotterInterface::class)->register($e);
25 28
         }
Please login to merge, or discard this patch.
tests/Framework/Module/PublishTest.php 2 patches
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,8 @@
 block discarded – undo
19 19
 
20 20
     public function tearDown()
21 21
     {
22
-        if (file_exists(self::TEST_FILE)) {
22
+        if (file_exists(self::TEST_FILE))
23
+        {
23 24
             unlink(self::TEST_FILE);
24 25
         }
25 26
 
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -14,12 +14,12 @@  discard block
 block discarded – undo
14 14
 
15 15
 class PublishTest extends ConsoleTest
16 16
 {
17
-    protected const TEST_FILE   = __DIR__ . '/test.txt';
18
-    protected const TEST_FILE_2 = __DIR__ . '/PublishTest.php';
17
+    protected const TEST_FILE   = __DIR__.'/test.txt';
18
+    protected const TEST_FILE_2 = __DIR__.'/PublishTest.php';
19 19
 
20 20
     public function tearDown()
21 21
     {
22
-        if (file_exists(self::TEST_FILE)) {
22
+        if (file_exists(self::TEST_FILE)){
23 23
             unlink(self::TEST_FILE);
24 24
         }
25 25
 
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
         $this->runCommandDebug('publish', [
176 176
             'type'   => 'replace',
177 177
             'target' => '@runtime',
178
-            'source' => __DIR__ . '/*',
178
+            'source' => __DIR__.'/*',
179 179
             'mode'   => 'runtime'
180 180
         ]);
181 181
 
@@ -193,7 +193,7 @@  discard block
 block discarded – undo
193 193
         $this->runCommandDebug('publish', [
194 194
             'type'   => 'follow',
195 195
             'target' => '@runtime',
196
-            'source' => __DIR__ . '/*',
196
+            'source' => __DIR__.'/*',
197 197
             'mode'   => 'runtime'
198 198
         ]);
199 199
 
@@ -211,7 +211,7 @@  discard block
 block discarded – undo
211 211
         $this->runCommandDebug('publish', [
212 212
             'type'   => 'follow',
213 213
             'target' => '@runtime/test.txt',
214
-            'source' => self::TEST_FILE . 'invalid',
214
+            'source' => self::TEST_FILE.'invalid',
215 215
             'mode'   => 'runtime'
216 216
         ]);
217 217
     }
@@ -226,13 +226,13 @@  discard block
 block discarded – undo
226 226
         $this->runCommandDebug('publish', [
227 227
             'type'   => 'follow',
228 228
             'target' => '@runtime/test.txt',
229
-            'source' => self::TEST_FILE . 'invalid/*',
229
+            'source' => self::TEST_FILE.'invalid/*',
230 230
             'mode'   => 'runtime'
231 231
         ]);
232 232
     }
233 233
 
234 234
     protected function file(string $dir, string $name)
235 235
     {
236
-        return $this->app->get(DirectoriesInterface::class)->get($dir) . $name;
236
+        return $this->app->get(DirectoriesInterface::class)->get($dir).$name;
237 237
     }
238 238
 }
Please login to merge, or discard this patch.
tests/app/src/ViewEngine/TestEngine.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
 
21 21
     public function compile(string $path, ContextInterface $context)
22 22
     {
23
-        if ($path == 'custom:error') {
23
+        if ($path == 'custom:error'){
24 24
             throw new EngineException("Unable to compile custom:error");
25 25
         }
26 26
     }
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,8 @@
 block discarded – undo
20 20
 
21 21
     public function compile(string $path, ContextInterface $context)
22 22
     {
23
-        if ($path == 'custom:error') {
23
+        if ($path == 'custom:error')
24
+        {
24 25
             throw new EngineException("Unable to compile custom:error");
25 26
         }
26 27
     }
Please login to merge, or discard this patch.
src/Bootloader/Security/ValidationBootloader.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -103,7 +103,7 @@
 block discarded – undo
103 103
             ]
104 104
         ]);
105 105
 
106
-        $tokenizer->addDirectory(directory('vendor') . 'spiral/validation/src/');
106
+        $tokenizer->addDirectory(directory('vendor').'spiral/validation/src/');
107 107
     }
108 108
 
109 109
     /**
Please login to merge, or discard this patch.
src/Bootloader/I18nBootloader.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -58,8 +58,8 @@
 block discarded – undo
58 58
      */
59 59
     public function boot(EnvironmentInterface $env, DirectoriesInterface $dirs)
60 60
     {
61
-        if (!$dirs->has('locale')) {
62
-            $dirs->set('locale', $dirs->get('app') . 'locale/');
61
+        if (!$dirs->has('locale')){
62
+            $dirs->set('locale', $dirs->get('app').'locale/');
63 63
         }
64 64
 
65 65
         $this->config->setDefaults('translator', [
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -58,7 +58,8 @@
 block discarded – undo
58 58
      */
59 59
     public function boot(EnvironmentInterface $env, DirectoriesInterface $dirs)
60 60
     {
61
-        if (!$dirs->has('locale')) {
61
+        if (!$dirs->has('locale'))
62
+        {
62 63
             $dirs->set('locale', $dirs->get('app') . 'locale/');
63 64
         }
64 65
 
Please login to merge, or discard this patch.
src/Bootloader/Views/ViewsBootloader.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -42,15 +42,15 @@  discard block
 block discarded – undo
42 42
      */
43 43
     public function boot(EnvironmentInterface $env, DirectoriesInterface $dirs)
44 44
     {
45
-        if (!$dirs->has('views')) {
46
-            $dirs->set('views', $dirs->get('app') . 'views');
45
+        if (!$dirs->has('views')){
46
+            $dirs->set('views', $dirs->get('app').'views');
47 47
         }
48 48
 
49 49
         // default view config
50 50
         $this->config->setDefaults('views', [
51 51
             'cache'        => [
52 52
                 'enabled'   => !$env->get('DEBUG', false),
53
-                'directory' => $dirs->get('cache') . 'views'
53
+                'directory' => $dirs->get('cache').'views'
54 54
             ],
55 55
             'namespaces'   => [
56 56
                 'default' => [$dirs->get('views')]
@@ -66,11 +66,11 @@  discard block
 block discarded – undo
66 66
      */
67 67
     public function addDirectory(string $namespace, string $directory)
68 68
     {
69
-        if (!isset($this->config->getConfig('views')['namespaces'][$namespace])) {
69
+        if (!isset($this->config->getConfig('views')['namespaces'][$namespace])){
70 70
             $this->config->modify('views', new Append('namespaces', $namespace, []));
71 71
         }
72 72
 
73
-        $this->config->modify('views', new Append('namespaces.' . $namespace, null, $directory));
73
+        $this->config->modify('views', new Append('namespaces.'.$namespace, null, $directory));
74 74
     }
75 75
 
76 76
     /**
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,7 +42,8 @@  discard block
 block discarded – undo
42 42
      */
43 43
     public function boot(EnvironmentInterface $env, DirectoriesInterface $dirs)
44 44
     {
45
-        if (!$dirs->has('views')) {
45
+        if (!$dirs->has('views'))
46
+        {
46 47
             $dirs->set('views', $dirs->get('app') . 'views');
47 48
         }
48 49
 
@@ -66,7 +67,8 @@  discard block
 block discarded – undo
66 67
      */
67 68
     public function addDirectory(string $namespace, string $directory)
68 69
     {
69
-        if (!isset($this->config->getConfig('views')['namespaces'][$namespace])) {
70
+        if (!isset($this->config->getConfig('views')['namespaces'][$namespace]))
71
+        {
70 72
             $this->config->modify('views', new Append('namespaces', $namespace, []));
71 73
         }
72 74
 
Please login to merge, or discard this patch.
src/Bootloader/Database/DisconnectsBootloader.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
         $finalizer->addFinalizer(function () use ($container) {
29 29
             /** @var DatabaseManager $dbal */
30 30
             $dbal = $container->get(DatabaseManager::class);
31
-            foreach ($dbal->getDrivers() as $driver) {
31
+            foreach ($dbal->getDrivers() as $driver){
32 32
                 $driver->disconnect();
33 33
             }
34 34
         });
Please login to merge, or discard this patch.
Braces   +4 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,10 +25,12 @@
 block discarded – undo
25 25
      */
26 26
     public function boot(FinalizerInterface $finalizer, ContainerInterface $container)
27 27
     {
28
-        $finalizer->addFinalizer(function () use ($container) {
28
+        $finalizer->addFinalizer(function () use ($container)
29
+        {
29 30
             /** @var DatabaseManager $dbal */
30 31
             $dbal = $container->get(DatabaseManager::class);
31
-            foreach ($dbal->getDrivers() as $driver) {
32
+            foreach ($dbal->getDrivers() as $driver)
33
+            {
32 34
                 $driver->disconnect();
33 35
             }
34 36
         });
Please login to merge, or discard this patch.
src/Bootloader/Database/MigrationsBootloader.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -35,9 +35,9 @@
 block discarded – undo
35 35
         ConfiguratorInterface $config,
36 36
         EnvironmentInterface $env,
37 37
         DirectoriesInterface $dirs
38
-    ) {
39
-        if (!$dirs->has('migrations')) {
40
-            $dirs->set('migrations', $dirs->get('app') . 'migrations');
38
+    ){
39
+        if (!$dirs->has('migrations')){
40
+            $dirs->set('migrations', $dirs->get('app').'migrations');
41 41
         }
42 42
 
43 43
         $config->setDefaults('migration', [
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -36,7 +36,8 @@
 block discarded – undo
36 36
         EnvironmentInterface $env,
37 37
         DirectoriesInterface $dirs
38 38
     ) {
39
-        if (!$dirs->has('migrations')) {
39
+        if (!$dirs->has('migrations'))
40
+        {
40 41
             $dirs->set('migrations', $dirs->get('app') . 'migrations');
41 42
         }
42 43
 
Please login to merge, or discard this patch.
src/Bootloader/ConsoleBootloader.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
         string $header,
94 94
         string $footer = '',
95 95
         array $options = []
96
-    ) {
96
+    ){
97 97
         $this->config->modify(
98 98
             'console',
99 99
             $this->sequence('configure', $sequence, $header, $footer, $options)
@@ -111,7 +111,7 @@  discard block
 block discarded – undo
111 111
         string $header,
112 112
         string $footer = '',
113 113
         array $options = []
114
-    ) {
114
+    ){
115 115
         $this->config->modify(
116 116
             'console',
117 117
             $this->sequence('update', $sequence, $header, $footer, $options)
@@ -133,7 +133,7 @@  discard block
 block discarded – undo
133 133
         string $footer,
134 134
         array $options
135 135
     ): Append {
136
-        if (is_array($sequence) || $sequence instanceof \Closure) {
136
+        if (is_array($sequence) || $sequence instanceof \Closure){
137 137
             return new Append(
138 138
                 $target,
139 139
                 null,
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -133,7 +133,8 @@
 block discarded – undo
133 133
         string $footer,
134 134
         array $options
135 135
     ): Append {
136
-        if (is_array($sequence) || $sequence instanceof \Closure) {
136
+        if (is_array($sequence) || $sequence instanceof \Closure)
137
+        {
137 138
             return new Append(
138 139
                 $target,
139 140
                 null,
Please login to merge, or discard this patch.