Completed
Pull Request — master (#55)
by Alexander
54s
created
src/Command/DebugTasksCommand.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
                     $execution->getHandlerClass(),
58 58
                     $execution->getScheduleTime()->format(\DateTime::RFC3339),
59 59
                     !$execution->getEndTime() ? '' : $execution->getEndTime()->format(\DateTime::RFC3339),
60
-                    (round($execution->getDuration(), 6) * 1000000) . 'ms',
60
+                    (round($execution->getDuration(), 6) * 1000000).'ms',
61 61
                 ]
62 62
             );
63 63
         }
Please login to merge, or discard this patch.
tests/Unit/Command/ScheduleSystemTasksCommandTest.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -161,7 +161,7 @@  discard block
 block discarded – undo
161 161
             $task->reveal()->getInterval(),
162 162
             $task->reveal()->getFirstExecution(),
163 163
             Argument::that(
164
-                function ($date) {
164
+                function($date) {
165 165
                     return $date <= new \DateTime('+1 Minute');
166 166
                 }
167 167
             )
@@ -270,7 +270,7 @@  discard block
 block discarded – undo
270 270
             $task->reveal()->getInterval(),
271 271
             $task->reveal()->getFirstExecution(),
272 272
             Argument::that(
273
-                function ($date) {
273
+                function($date) {
274 274
                     return $date <= new \DateTime('+1 Minute');
275 275
                 }
276 276
             )
Please login to merge, or discard this patch.
src/DependencyInjection/TaskExtension.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -40,10 +40,10 @@  discard block
 block discarded – undo
40 40
 
41 41
         $container->setAlias('task.lock.storage', $configuration->getLockingStorageId($config['locking']['storage']));
42 42
         foreach (array_keys($config['locking']['storages']) as $key) {
43
-            $container->setParameter('task.lock.storages.' . $key, $config['locking']['storages'][$key]);
43
+            $container->setParameter('task.lock.storages.'.$key, $config['locking']['storages'][$key]);
44 44
         }
45 45
 
46
-        $loader = new Loader\XmlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config'));
46
+        $loader = new Loader\XmlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
47 47
         $loader->load(sprintf('storage/%s.xml', $config['storage']));
48 48
         $loader->load('task_event_listener.xml');
49 49
         $loader->load('scheduler.xml');
@@ -106,15 +106,15 @@  discard block
 block discarded – undo
106 106
      */
107 107
     private function loadExecutorComponent(array $config, ContainerBuilder $container, LoaderInterface $loader)
108 108
     {
109
-        $loader->load('executor/' . $config['type'] . '.xml');
110
-        $container->setAlias('task.executor', 'task.executor.' . $config['type']);
109
+        $loader->load('executor/'.$config['type'].'.xml');
110
+        $container->setAlias('task.executor', 'task.executor.'.$config['type']);
111 111
 
112 112
         if (!array_key_exists($config['type'], $config)) {
113 113
             return;
114 114
         }
115 115
 
116 116
         foreach ($config[$config['type']] as $key => $value) {
117
-            $container->setParameter('task.executor.' . $key, $value);
117
+            $container->setParameter('task.executor.'.$key, $value);
118 118
         }
119 119
 
120 120
         if (!file_exists($container->getParameter('task.executor.console_path'))) {
@@ -150,7 +150,7 @@  discard block
 block discarded – undo
150 150
      */
151 151
     public function getConfiguration(array $config, ContainerBuilder $container)
152 152
     {
153
-        $loader = new Loader\XmlFileLoader($container, new FileLocator(__DIR__ . '/../Resources/config'));
153
+        $loader = new Loader\XmlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config'));
154 154
         $loader->load('locking/storages.xml');
155 155
 
156 156
         return new Configuration($this->getLockingStorageAliases($container));
Please login to merge, or discard this patch.
tests/Unit/Executor/SeparateProcessExecutorTest.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -129,7 +129,7 @@  discard block
 block discarded – undo
129 129
         $this->process->run()->shouldBeCalled();
130 130
         $this->process->isSuccessful()->willReturn(false);
131 131
 
132
-        $this->process->getErrorOutput()->willReturn(FailedException::class . PHP_EOL . 'TEST');
132
+        $this->process->getErrorOutput()->willReturn(FailedException::class.PHP_EOL.'TEST');
133 133
 
134 134
         try {
135 135
             $this->executor->execute($this->execution->reveal());
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
         $this->process->run()->shouldBeCalledTimes(1);
153 153
         $this->process->isSuccessful()->willReturn(false);
154 154
 
155
-        $this->process->getErrorOutput()->willReturn(FailedException::class . PHP_EOL . 'TEST');
155
+        $this->process->getErrorOutput()->willReturn(FailedException::class.PHP_EOL.'TEST');
156 156
 
157 157
         try {
158 158
             $this->executor->execute($this->execution->reveal());
@@ -172,14 +172,14 @@  discard block
 block discarded – undo
172 172
 
173 173
         $attempts = 1;
174 174
         $this->execution->incrementAttempts()->will(
175
-            function () use (&$attempts) {
175
+            function() use (&$attempts) {
176 176
                 ++$attempts;
177 177
 
178 178
                 return $this;
179 179
             }
180 180
         );
181 181
         $this->execution->getAttempts()->will(
182
-            function () use (&$attempts) {
182
+            function() use (&$attempts) {
183 183
                 return $attempts;
184 184
             }
185 185
         );
Please login to merge, or discard this patch.
src/Executor/ExecutionProcessFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@
 block discarded – undo
45 45
      */
46 46
     public function create($uuid)
47 47
     {
48
-        $command = implode(' ', [$this->consolePath, 'task:execute', $uuid, '--env=' . $this->environment]);
48
+        $command = implode(' ', [$this->consolePath, 'task:execute', $uuid, '--env='.$this->environment]);
49 49
 
50 50
         if (method_exists(Process::class, 'fromShellCommandline')) {
51 51
             $process = Process::fromShellCommandline($command);
Please login to merge, or discard this patch.
tests/app/TestKernel.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -59,7 +59,7 @@
 block discarded – undo
59 59
     protected function buildContainer(): ContainerBuilder
60 60
     {
61 61
         $container = parent::buildContainer();
62
-        $loader = new XmlFileLoader($container, new FileLocator(__DIR__ . '/config'));
62
+        $loader = new XmlFileLoader($container, new FileLocator(__DIR__.'/config'));
63 63
         $loader->load('services.xml');
64 64
 
65 65
         $container->setParameter('kernel.storage', $this->storage);
Please login to merge, or discard this patch.
tests/bootstrap.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -2,14 +2,14 @@
 block discarded – undo
2 2
 
3 3
 use Doctrine\Common\Annotations\AnnotationRegistry;
4 4
 
5
-$file = __DIR__ . '/../vendor/autoload.php';
5
+$file = __DIR__.'/../vendor/autoload.php';
6 6
 if (!file_exists($file)) {
7 7
     throw new RuntimeException('Install dependencies to run test suite.');
8 8
 }
9 9
 
10 10
 $loader = require $file;
11 11
 
12
-require __DIR__ . '/app/TestKernel.php';
12
+require __DIR__.'/app/TestKernel.php';
13 13
 
14 14
 if (\class_exists(AnnotationRegistry::class)) {
15 15
     AnnotationRegistry::registerLoader([$loader, 'loadClass']);
Please login to merge, or discard this patch.