Completed
Push — master ( 424df6...6d7ac3 )
by Joao
9s
created
src/Console/DatabaseVersionCommand.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,8 +27,8 @@
 block discarded – undo
27 27
         parent::execute($input, $output);
28 28
         try {
29 29
             $versionInfo = $this->migration->getCurrentVersion();
30
-            $output->writeln('version: ' . $versionInfo['version']);
31
-            $output->writeln('status.: ' . $versionInfo['status']);
30
+            $output->writeln('version: ' . $versionInfo[ 'version' ]);
31
+            $output->writeln('status.: ' . $versionInfo[ 'status' ]);
32 32
         } catch (\Exception $ex) {
33 33
             $this->handleError($ex, $output);
34 34
         }
Please login to merge, or discard this patch.
src/Console/DownCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
     {
28 28
         try {
29 29
             $versionInfo = $this->migration->getCurrentVersion();
30
-            if (strpos($versionInfo['status'], 'partial') !== false) {
30
+            if (strpos($versionInfo[ 'status' ], 'partial') !== false) {
31 31
                 $helper = $this->getHelper('question');
32 32
                 $question = new ConfirmationQuestion(
33 33
                     'The database was not fully updated and maybe be unstable. Did you really want migrate the version? (y/N)',
Please login to merge, or discard this patch.
src/Console/UpdateCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
     {
30 30
         try {
31 31
             $versionInfo = $this->migration->getCurrentVersion();
32
-            if (strpos($versionInfo['status'], 'partial') !== false) {
32
+            if (strpos($versionInfo[ 'status' ], 'partial') !== false) {
33 33
                 $helper = $this->getHelper('question');
34 34
                 $question = new ConfirmationQuestion(
35 35
                     'The database was not fully updated and maybe be unstable. Did you really want migrate the version? (y/N) ',
Please login to merge, or discard this patch.
src/Console/InstallCommand.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -42,8 +42,8 @@
 block discarded – undo
42 42
 
43 43
             $version = $this->migration->getCurrentVersion();
44 44
             $output->writeln($action);
45
-            $output->writeln('current version: ' . $version['version']);
46
-            $output->writeln('current status.: ' . $version['status']);
45
+            $output->writeln('current version: ' . $version[ 'version' ]);
46
+            $output->writeln('current status.: ' . $version[ 'status' ]);
47 47
         } catch (\Exception $ex) {
48 48
             $this->handleError($ex, $output);
49 49
         }
Please login to merge, or discard this patch.
src/Database/PgsqlDatabase.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@
 block discarded – undo
25 25
     {
26 26
         $currentDbName = $dbDriver->getScalar(
27 27
             "SELECT datname FROM pg_catalog.pg_database WHERE lower(datname) = lower(:dbname)",
28
-            ['dbname' => $database]
28
+            [ 'dbname' => $database ]
29 29
         );
30 30
 
31 31
         if (empty($currentDbName)) {
Please login to merge, or discard this patch.
tests/BaseDatabase.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -67,16 +67,16 @@  discard block
 block discarded – undo
67 67
     protected function getExpectedUsersVersion0()
68 68
     {
69 69
         return [
70
-            ["id" => 1, "name" => 'John Doe', 'createdate' => '20160110'],
71
-            ["id" => 2, "name" => 'Jane Doe', 'createdate' => '20151230']
70
+            [ "id" => 1, "name" => 'John Doe', 'createdate' => '20160110' ],
71
+            [ "id" => 2, "name" => 'Jane Doe', 'createdate' => '20151230' ]
72 72
         ];
73 73
     }
74 74
 
75 75
     protected function getExpectedUsersVersion1()
76 76
     {
77 77
         return [
78
-            ["id" => 1, "name" => 'John Doe', 'createdate' => '2016-01-10'],
79
-            ["id" => 2, "name" => 'Jane Doe', 'createdate' => '2015-12-30']
78
+            [ "id" => 1, "name" => 'John Doe', 'createdate' => '2016-01-10' ],
79
+            [ "id" => 2, "name" => 'Jane Doe', 'createdate' => '2015-12-30' ]
80 80
         ];
81 81
     }
82 82
 
@@ -90,14 +90,14 @@  discard block
 block discarded – undo
90 90
         $this->assertTrue($iterator->hasNext());
91 91
         $row = $iterator->moveNext();
92 92
         $this->assertEquals(
93
-            $this->getExpectedUsersVersion0()[0],
93
+            $this->getExpectedUsersVersion0()[ 0 ],
94 94
             $row->toArray()
95 95
         );
96 96
 
97 97
         $this->assertTrue($iterator->hasNext());
98 98
         $row = $iterator->moveNext();
99 99
         $this->assertEquals(
100
-            $this->getExpectedUsersVersion0()[1],
100
+            $this->getExpectedUsersVersion0()[ 1 ],
101 101
             $row->toArray()
102 102
         );
103 103
 
@@ -120,14 +120,14 @@  discard block
 block discarded – undo
120 120
         $this->assertTrue($iterator->hasNext());
121 121
         $row = $iterator->moveNext();
122 122
         $this->assertEquals(
123
-            $this->getExpectedUsersVersion1()[0],
123
+            $this->getExpectedUsersVersion1()[ 0 ],
124 124
             $row->toArray()
125 125
         );
126 126
 
127 127
         $this->assertTrue($iterator->hasNext());
128 128
         $row = $iterator->moveNext();
129 129
         $this->assertEquals(
130
-            $this->getExpectedUsersVersion1()[1],
130
+            $this->getExpectedUsersVersion1()[ 1 ],
131 131
             $row->toArray()
132 132
         );
133 133
 
@@ -150,14 +150,14 @@  discard block
 block discarded – undo
150 150
         $this->assertTrue($iterator->hasNext());
151 151
         $row = $iterator->moveNext();
152 152
         $this->assertEquals(
153
-            $this->getExpectedUsersVersion1()[0],
153
+            $this->getExpectedUsersVersion1()[ 0 ],
154 154
             $row->toArray()
155 155
         );
156 156
 
157 157
         $this->assertTrue($iterator->hasNext());
158 158
         $row = $iterator->moveNext();
159 159
         $this->assertEquals(
160
-            $this->getExpectedUsersVersion1()[1],
160
+            $this->getExpectedUsersVersion1()[ 1 ],
161 161
             $row->toArray()
162 162
         );
163 163
 
Please login to merge, or discard this patch.
tests/SqlServerDatabaseTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -14,8 +14,8 @@
 block discarded – undo
14 14
     public function getExpectedUsersVersion1()
15 15
     {
16 16
         return [
17
-            ["id" => 1, "name" => 'John Doe', 'createdate' => 'Jan 10 2016 12:00:00:AM'],
18
-            ["id" => 2, "name" => 'Jane Doe', 'createdate' => 'Dec 30 2015 12:00:00:AM']
17
+            [ "id" => 1, "name" => 'John Doe', 'createdate' => 'Jan 10 2016 12:00:00:AM' ],
18
+            [ "id" => 2, "name" => 'Jane Doe', 'createdate' => 'Dec 30 2015 12:00:00:AM' ]
19 19
         ];
20 20
     }
21 21
 
Please login to merge, or discard this patch.
src/Console/UpCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
     {
30 30
         try {
31 31
             $versionInfo = $this->migration->getCurrentVersion();
32
-            if (strpos($versionInfo['status'], 'partial') !== false) {
32
+            if (strpos($versionInfo[ 'status' ], 'partial') !== false) {
33 33
                 $helper = $this->getHelper('question');
34 34
                 $question = new ConfirmationQuestion(
35 35
                     'The database was not fully updated and maybe be unstable. Did you really want migrate the version? (y/N) ',
Please login to merge, or discard this patch.
src/Console/ConsoleCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -84,7 +84,7 @@
 block discarded – undo
84 84
         }
85 85
 
86 86
         if ($output->getVerbosity() >= OutputInterface::VERBOSITY_VERY_VERBOSE) {
87
-            $this->migration->addCallbackProgress(function ($command, $version) use ($output) {
87
+            $this->migration->addCallbackProgress(function($command, $version) use ($output) {
88 88
                 $output->writeln('Doing: ' . $command . " to " . $version);
89 89
             });
90 90
         }
Please login to merge, or discard this patch.