Completed
Push — master ( 3abfec...c553e5 )
by Mikael
02:58
created
sources/tests/Unit/Command/InspectConfig.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
     {
25 25
         $pomm_mock = new \mock\PommProject\Foundation\Pomm;
26 26
 
27
-        $pomm_mock->getMockController()->getSessionBuilders = function () use ($nb_builder) {
27
+        $pomm_mock->getMockController()->getSessionBuilders = function() use ($nb_builder) {
28 28
             $builders = [];
29 29
 
30 30
             for ($i = 0; $i < $nb_builder; $i++) {
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
             return $builders;
35 35
         };
36 36
 
37
-        $pomm_mock->getMockController()->isDefaultSession = function ($name) {
37
+        $pomm_mock->getMockController()->isDefaultSession = function($name) {
38 38
             if ($name == "my_db0") {
39 39
                 return true;
40 40
             }
Please login to merge, or discard this patch.
sources/tests/Unit/Command/GenerateEntity.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@
 block discarded – undo
62 62
         $this
63 63
             ->string($tester->getDisplay())
64 64
             ->isEqualTo(" ✓  Overwriting file 'tmp/Model/PommTest/PommTestSchema/Alpha.php'.".PHP_EOL)
65
-         ;
65
+            ;
66 66
 
67 67
         $tester->execute(array_merge($command_args, ['--flexible-container' => 'Model\\PommTest\\PommTestSchema\\CustomFlexibleEntity', '--force' => null ]), $options);
68 68
         $this
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -54,26 +54,26 @@
 block discarded – undo
54 54
             ->isEqualTo(" ✓  Creating file 'tmp/Model/PommTest/PommTestSchema/Alpha.php'.".PHP_EOL)
55 55
             ->string(file_get_contents('tmp/Model/PommTest/PommTestSchema/Alpha.php'))
56 56
             ->isEqualTo(file_get_contents('sources/tests/Fixture/AlphaEntity.php'))
57
-            ->exception(function () use ($tester, $command, $command_args) {
57
+            ->exception(function() use ($tester, $command, $command_args) {
58 58
                 $tester->execute($command_args);
59 59
             })
60 60
             ->isInstanceOf('\PommProject\ModelManager\Exception\GeneratorException')
61 61
             ->message->contains('--force')
62 62
             ;
63
-        $tester->execute(array_merge($command_args, ['--force' => null ]), $options);
63
+        $tester->execute(array_merge($command_args, ['--force' => null]), $options);
64 64
         $this
65 65
             ->string($tester->getDisplay())
66 66
             ->isEqualTo(" ✓  Overwriting file 'tmp/Model/PommTest/PommTestSchema/Alpha.php'.".PHP_EOL)
67 67
          ;
68 68
 
69
-        $tester->execute(array_merge($command_args, ['--flexible-container' => 'Model\\PommTest\\PommTestSchema\\CustomFlexibleEntity', '--force' => null ]), $options);
69
+        $tester->execute(array_merge($command_args, ['--flexible-container' => 'Model\\PommTest\\PommTestSchema\\CustomFlexibleEntity', '--force' => null]), $options);
70 70
         $this
71 71
             ->string(file_get_contents('tmp/Model/PommTest/PommTestSchema/Alpha.php'))
72 72
             ->isEqualTo(file_get_contents('sources/tests/Fixture/CustomAlphaEntity.php'))
73 73
         ;
74 74
 
75 75
         $command_args['--prefix-dir'] = "tmp/Model";
76
-        $tester->execute(array_merge($command_args, ['--psr4' => null, '--force' => null ]), $options);
76
+        $tester->execute(array_merge($command_args, ['--psr4' => null, '--force' => null]), $options);
77 77
         $this
78 78
             ->string($tester->getDisplay())
79 79
             ->isEqualTo(" ✓  Overwriting file 'tmp/Model/PommTest/PommTestSchema/Alpha.php'.".PHP_EOL)
Please login to merge, or discard this patch.
sources/tests/Unit/Command/InspectSchema.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -62,7 +62,7 @@
 block discarded – undo
62 62
         }
63 63
 
64 64
         $this
65
-            ->exception(function () use ($tester, $command) {
65
+            ->exception(function() use ($tester, $command) {
66 66
                     $tester->execute(
67 67
                         [
68 68
                             'command'          => $command->getName(),
Please login to merge, or discard this patch.
sources/tests/Unit/Command/GenerateRelationStructure.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@
 block discarded – undo
63 63
             ->isEqualTo(file_get_contents('sources/tests/Fixture/BetaStructure.php'))
64 64
             ;
65 65
         $command_args['--prefix-dir'] = "tmp/Model";
66
-        $tester->execute(array_merge($command_args, ['--psr4' => null ]), $options);
66
+        $tester->execute(array_merge($command_args, ['--psr4' => null]), $options);
67 67
         $this
68 68
             ->string($tester->getDisplay())
69 69
             ->isEqualTo(" ✓  Overwriting file 'tmp/Model/PommTest/PommTestSchema/AutoStructure/Beta.php'.".PHP_EOL)
Please login to merge, or discard this patch.
sources/tests/Unit/Command/GenerateRelationModel.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -56,13 +56,13 @@  discard block
 block discarded – undo
56 56
             ->isEqualTo(" ✓  Creating file 'tmp/Model/PommTest/PommTestSchema/BetaModel.php'.".PHP_EOL)
57 57
             ->string(file_get_contents('tmp/Model/PommTest/PommTestSchema/BetaModel.php'))
58 58
             ->isEqualTo(file_get_contents('sources/tests/Fixture/BetaModel.php'))
59
-            ->exception(function () use ($tester, $command, $command_args) {
59
+            ->exception(function() use ($tester, $command, $command_args) {
60 60
                 $tester->execute($command_args);
61 61
             })
62 62
             ->isInstanceOf('\PommProject\ModelManager\Exception\GeneratorException')
63 63
             ->message->contains('--force')
64 64
             ;
65
-        $tester->execute(array_merge($command_args, ['--force' => null ]), $options);
65
+        $tester->execute(array_merge($command_args, ['--force' => null]), $options);
66 66
         $this
67 67
             ->string($tester->getDisplay())
68 68
             ->isEqualTo(" ✓  Overwriting file 'tmp/Model/PommTest/PommTestSchema/BetaModel.php'.".PHP_EOL)
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
                 ;
91 91
         }
92 92
         $command_args['--prefix-dir'] = "tmp/Model";
93
-        $tester->execute(array_merge($command_args, ['--psr4' => null, '--force' => null ]), $options);
93
+        $tester->execute(array_merge($command_args, ['--psr4' => null, '--force' => null]), $options);
94 94
         $this
95 95
             ->string($tester->getDisplay())
96 96
             ->isEqualTo(" ✓  Overwriting file 'tmp/Model/PommTest/PommTestSchema/BetaModel.php'.".PHP_EOL)
Please login to merge, or discard this patch.
sources/tests/Unit/Command/InspectRelation.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@
 block discarded – undo
56 56
             ->matches('#Relation pomm_test.beta \\(size with indexes\\: [0-9]+ bytes\\)#')
57 57
         ;
58 58
         $this
59
-            ->exception(function () use ($tester, $command) {
59
+            ->exception(function() use ($tester, $command) {
60 60
                     $tester->execute(
61 61
                         [
62 62
                             'command'          => $command->getName(),
Please login to merge, or discard this patch.
sources/lib/Command/InspectType.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@
 block discarded – undo
56 56
             ->getPoolerForType('converter')
57 57
             ->getConverterHolder()
58 58
             ->getTypes();
59
-        $types = array_filter($types, function ($type) {
59
+        $types = array_filter($types, function($type) {
60 60
             return !preg_match('/^pg_catalog\./', $type);
61 61
         });
62 62
         natcasesort($types);
Please login to merge, or discard this patch.
sources/lib/Command/SchemaAwareCommand.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -98,7 +98,7 @@  discard block
 block discarded – undo
98 98
     protected function execute(InputInterface $input, OutputInterface $output)
99 99
     {
100 100
         parent::execute($input, $output);
101
-        $this->schema   = $input->getArgument('schema');
101
+        $this->schema = $input->getArgument('schema');
102 102
 
103 103
         if (!$this->schema) {
104 104
             $this->schema = 'public';
@@ -141,7 +141,7 @@  discard block
 block discarded – undo
141 141
                 sprintf("%s%s.php", Inflector::studlyCaps($file_name), $file_suffix)
142 142
             ];
143 143
 
144
-        return join('/', array_filter($elements, function ($val) {
144
+        return join('/', array_filter($elements, function($val) {
145 145
             return $val != null;
146 146
         }));
147 147
     }
@@ -166,7 +166,7 @@  discard block
 block discarded – undo
166 166
                 $extra_ns
167 167
             ];
168 168
 
169
-        return join('\\', array_filter($elements, function ($val) {
169
+        return join('\\', array_filter($elements, function($val) {
170 170
             return $val != null;
171 171
         }));
172 172
     }
Please login to merge, or discard this patch.
sources/lib/Command/RelationAwareCommand.php 1 patch
Switch Indentation   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -75,17 +75,17 @@
 block discarded – undo
75 75
             $status = $line["status"] == "ok" ? "<fg=green>✓</fg=green>" : "<fg=red>✗</fg=red>";
76 76
 
77 77
             switch ($line['operation']) {
78
-                case "creating":
79
-                    $operation = sprintf("<fg=green>%s</fg=green>", ucwords($line['operation']));
80
-                    break;
81
-                case "overwriting":
82
-                    $operation = sprintf("<fg=cyan>%s</fg=cyan>", ucwords($line['operation']));
83
-                    break;
84
-                case "deleting":
85
-                    $operation = sprintf("<fg=red>%s</fg=red>", ucwords($line['operation']));
86
-                    break;
87
-                default:
88
-                    $operation = ucwords($line['operation']);
78
+            case "creating":
79
+                $operation = sprintf("<fg=green>%s</fg=green>", ucwords($line['operation']));
80
+                break;
81
+            case "overwriting":
82
+                $operation = sprintf("<fg=cyan>%s</fg=cyan>", ucwords($line['operation']));
83
+                break;
84
+            case "deleting":
85
+                $operation = sprintf("<fg=red>%s</fg=red>", ucwords($line['operation']));
86
+                break;
87
+            default:
88
+                $operation = ucwords($line['operation']);
89 89
             }
90 90
 
91 91
             $output->writeln(
Please login to merge, or discard this patch.