Completed
Push — 18.x ( c45293...abfd48 )
by Tim
04:52
created
tests/unit/Observers/CatalogAttributeUpdateObserverTest.php 1 patch
Indentation   +17 added lines, -17 removed lines patch added patch discarded remove patch
@@ -62,8 +62,8 @@  discard block
 block discarded – undo
62 62
 
63 63
         // mock the attribute bunch processor
64 64
         $this->mockBunchProcessor = $this->getMockBuilder('TechDivision\Import\Attribute\Services\AttributeBunchProcessorInterface')
65
-                                         ->setMethods(get_class_methods('TechDivision\Import\Attribute\Services\AttributeBunchProcessorInterface'))
66
-                                         ->getMock();
65
+                                            ->setMethods(get_class_methods('TechDivision\Import\Attribute\Services\AttributeBunchProcessorInterface'))
66
+                                            ->getMock();
67 67
 
68 68
         // the observer instance we want to test
69 69
         $this->observer = new CatalogAttributeUpdateObserver($this->mockBunchProcessor);
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
                         array(ColumnKeys::IS_FILTERABLE_IN_GRID),
117 117
                         array(ColumnKeys::SEARCH_WEIGHT),
118 118
                         array(ColumnKeys::ADDITIONAL_DATA)
119
-                     )
119
+                        )
120 120
                     ->willReturnOnConsecutiveCalls(
121 121
                         true,
122 122
                         false,
@@ -189,14 +189,14 @@  discard block
 block discarded – undo
189 189
 
190 190
         // mock the method that loads the existing entity
191 191
         $this->mockBunchProcessor->expects($this->once())
192
-                                 ->method('loadCatalogAttribute')
193
-                                 ->with($lastAttributeId)
194
-                                 ->willReturn($existingEntity);
192
+                                    ->method('loadCatalogAttribute')
193
+                                    ->with($lastAttributeId)
194
+                                    ->willReturn($existingEntity);
195 195
         // mock the method that persists the entity
196 196
         $this->mockBunchProcessor->expects($this->once())
197
-                                 ->method('persistCatalogAttribute')
198
-                                 ->with($expectedEntity)
199
-                                 ->willReturn(null);
197
+                                    ->method('persistCatalogAttribute')
198
+                                    ->with($expectedEntity)
199
+                                    ->willReturn(null);
200 200
 
201 201
         // invoke the handle method
202 202
         $this->assertSame($row, $this->observer->handle($mockSubject));
@@ -309,7 +309,7 @@  discard block
 block discarded – undo
309 309
                         array(ColumnKeys::ADDITIONAL_DATA),
310 310
                         array(ColumnKeys::ATTRIBUTE_OPTION_VALUES),
311 311
                         array(ColumnKeys::ATTRIBUTE_OPTION_SWATCH)
312
-                     )
312
+                        )
313 313
                     ->willReturnOnConsecutiveCalls(
314 314
                         0,
315 315
                         1,
@@ -359,7 +359,7 @@  discard block
 block discarded – undo
359 359
                         23,
360 360
                         7,
361 361
                         8
362
-                     );
362
+                        );
363 363
         $mockSubject->expects($this->once())
364 364
                     ->method('hasBeenProcessed')
365 365
                     ->with($attributeCode)
@@ -444,14 +444,14 @@  discard block
 block discarded – undo
444 444
 
445 445
         // mock the method that loads the existing entity
446 446
         $this->mockBunchProcessor->expects($this->once())
447
-                                 ->method('loadCatalogAttribute')
448
-                                 ->with($lastAttributeId)
449
-                                 ->willReturn($existingEntity);
447
+                                    ->method('loadCatalogAttribute')
448
+                                    ->with($lastAttributeId)
449
+                                    ->willReturn($existingEntity);
450 450
         // mock the method that persists the entity
451 451
         $this->mockBunchProcessor->expects($this->once())
452
-                                 ->method('persistCatalogAttribute')
453
-                                 ->with($expectedEntity)
454
-                                 ->willReturn(null);
452
+                                    ->method('persistCatalogAttribute')
453
+                                    ->with($expectedEntity)
454
+                                    ->willReturn(null);
455 455
 
456 456
         // invoke the handle method
457 457
         $this->assertSame($row, $this->observer->handle($mockSubject));
Please login to merge, or discard this patch.
tests/unit/Observers/CatalogAttributeObserverTest.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -62,8 +62,8 @@  discard block
 block discarded – undo
62 62
 
63 63
         // mock the attribute bunch processor
64 64
         $this->mockBunchProcessor = $this->getMockBuilder('TechDivision\Import\Attribute\Services\AttributeBunchProcessorInterface')
65
-                                         ->setMethods(get_class_methods('TechDivision\Import\Attribute\Services\AttributeBunchProcessorInterface'))
66
-                                         ->getMock();
65
+                                            ->setMethods(get_class_methods('TechDivision\Import\Attribute\Services\AttributeBunchProcessorInterface'))
66
+                                            ->getMock();
67 67
 
68 68
         // the observer instance we want to test
69 69
         $this->observer = new CatalogAttributeObserver($this->mockBunchProcessor);
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
                         array(ColumnKeys::IS_FILTERABLE_IN_GRID),
117 117
                         array(ColumnKeys::SEARCH_WEIGHT),
118 118
                         array(ColumnKeys::ADDITIONAL_DATA)
119
-                     )
119
+                        )
120 120
                     ->willReturnOnConsecutiveCalls(
121 121
                         true,
122 122
                         false,
@@ -163,9 +163,9 @@  discard block
 block discarded – undo
163 163
 
164 164
         // mock the method that persists the entity
165 165
         $this->mockBunchProcessor->expects($this->once())
166
-                                 ->method('persistCatalogAttribute')
167
-                                 ->with($expectedEntity)
168
-                                 ->willReturn(null);
166
+                                    ->method('persistCatalogAttribute')
167
+                                    ->with($expectedEntity)
168
+                                    ->willReturn(null);
169 169
 
170 170
         // invoke the handle method
171 171
         $this->assertSame($row, $this->observer->handle($mockSubject));
Please login to merge, or discard this patch.
RoboFile.php 1 patch
Indentation   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -57,9 +57,9 @@  discard block
 block discarded – undo
57 57
     {
58 58
         // optimize autoloader with custom path
59 59
         return $this->taskComposerInstall()
60
-             ->preferDist()
61
-             ->optimizeAutoloader()
62
-             ->run();
60
+                ->preferDist()
61
+                ->optimizeAutoloader()
62
+                ->run();
63 63
     }
64 64
 
65 65
     /**
@@ -71,9 +71,9 @@  discard block
 block discarded – undo
71 71
     {
72 72
         // optimize autoloader with custom path
73 73
         return $this->taskComposerUpdate()
74
-             ->preferDist()
75
-             ->optimizeAutoloader()
76
-             ->run();
74
+                ->preferDist()
75
+                ->optimizeAutoloader()
76
+                ->run();
77 77
     }
78 78
 
79 79
     /**
@@ -94,10 +94,10 @@  discard block
 block discarded – undo
94 94
     public function prepare()
95 95
     {
96 96
         return $this->taskFileSystemStack()
97
-             ->mkdir($this->properties['dist.dir'])
98
-             ->mkdir($this->properties['target.dir'])
99
-             ->mkdir(sprintf('%s/reports', $this->properties['target.dir']))
100
-             ->run();
97
+                ->mkdir($this->properties['dist.dir'])
98
+                ->mkdir($this->properties['target.dir'])
99
+                ->mkdir(sprintf('%s/reports', $this->properties['target.dir']))
100
+                ->run();
101 101
     }
102 102
 
103 103
     /**
@@ -167,8 +167,8 @@  discard block
 block discarded – undo
167 167
 
168 168
         // run PHPUnit
169 169
         return $this->taskPHPUnit(sprintf('%s/bin/phpunit', $this->properties['vendor.dir']))
170
-             ->configFile('phpunit.xml')
171
-             ->run();
170
+                ->configFile('phpunit.xml')
171
+                ->run();
172 172
     }
173 173
 
174 174
     /**
Please login to merge, or discard this patch.