Completed
Push — master ( 335f7c...925222 )
by Nils
02:44
created
src/Extensions/SmokeReporter/Reporter/LeankoalaReporter.php 2 patches
Doc Comments   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -198,12 +198,12 @@
 block discarded – undo
198 198
     }
199 199
 
200 200
     /**
201
-     * @param $identifier
201
+     * @param string $identifier
202 202
      * @param $system
203
-     * @param $message
203
+     * @param string $message
204 204
      * @param $status
205 205
      * @param $value
206
-     * @param $tool
206
+     * @param string $tool
207 207
      * @param $component
208 208
      * @param Attribute[] $attributes
209 209
      */
Please login to merge, or discard this patch.
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
         foreach ($this->results as $results) {
119 119
             foreach ($results as $result) {
120 120
                 /* @var CheckResult $result */
121
-                $tool = 'Smoke' . $result->getRuleName();
121
+                $tool = 'Smoke'.$result->getRuleName();
122 122
                 $checks[$tool][] = $result;
123 123
             }
124 124
         }
@@ -130,19 +130,19 @@  discard block
 block discarded – undo
130 130
                 continue;
131 131
             }
132 132
 
133
-            $message = 'The smoke test for #system_name# failed (Rule: ' . $toolName . ').<ul>';
133
+            $message = 'The smoke test for #system_name# failed (Rule: '.$toolName.').<ul>';
134 134
             $status = Event::STATUS_SUCCESS;
135 135
             $failureCount = 0;
136
-            $identifier = $toolName . '_' . $this->system;
136
+            $identifier = $toolName.'_'.$this->system;
137 137
 
138 138
             foreach ($results as $result) {
139 139
                 /** @var CheckResult $result */
140 140
                 if ($result->getStatus() === CheckResult::STATUS_FAILURE) {
141 141
                     $comingFrom = '';
142 142
                     if ($this->addComingFrom && $this->retriever->getComingFrom($result->getResponse()->getUri())) {
143
-                        $comingFrom = ', coming from: ' . $this->retriever->getComingFrom($result->getResponse()->getUri());
143
+                        $comingFrom = ', coming from: '.$this->retriever->getComingFrom($result->getResponse()->getUri());
144 144
                     }
145
-                    $message .= '<li>' . $result->getMessage() . ' (url: ' . (string)$result->getResponse()->getUri() . $comingFrom . ')</li>';
145
+                    $message .= '<li>'.$result->getMessage().' (url: '.(string) $result->getResponse()->getUri().$comingFrom.')</li>';
146 146
                     ++$failureCount;
147 147
                 }
148 148
             }
@@ -151,10 +151,10 @@  discard block
 block discarded – undo
151 151
                 $message .= '</ul>';
152 152
                 $firstResult = array_pop($results);
153 153
                 if ($firstResult) {
154
-                    $attributes[] = new Attribute('html-content', (string)$firstResult->getResponse()->getBody(), true);
154
+                    $attributes[] = new Attribute('html-content', (string) $firstResult->getResponse()->getBody(), true);
155 155
                 }
156 156
             } else {
157
-                $message = 'All checks for system "#system_name#" succeeded [SmokeBasic:' . $toolName . '].';
157
+                $message = 'All checks for system "#system_name#" succeeded [SmokeBasic:'.$toolName.'].';
158 158
             }
159 159
 
160 160
 
@@ -168,7 +168,7 @@  discard block
 block discarded – undo
168 168
             foreach ($results as $result) {
169 169
                 /* @var CheckResult $result */
170 170
 
171
-                $identifier = '_' . $this->getIdentifier($result);
171
+                $identifier = '_'.$this->getIdentifier($result);
172 172
                 $tool = $this->getPrefix($result->getRuleName());
173 173
 
174 174
                 $component = $this->getComponent($result->getRuleName());
@@ -177,7 +177,7 @@  discard block
 block discarded – undo
177 177
                 $this->send(
178 178
                     $identifier,
179 179
                     $system,
180
-                    $result->getMessage() . ' (url: ' . (string)$result->getResponse()->getUri() . ')',
180
+                    $result->getMessage().' (url: '.(string) $result->getResponse()->getUri().')',
181 181
                     $result->getStatus(),
182 182
                     $result->getValue(),
183 183
                     $tool,
@@ -189,7 +189,7 @@  discard block
 block discarded – undo
189 189
 
190 190
     private function getIdentifier(CheckResult $result)
191 191
     {
192
-        return $this->tool . '_' . $result->getRuleName();
192
+        return $this->tool.'_'.$result->getRuleName();
193 193
     }
194 194
 
195 195
     private function getPrefix($string)
Please login to merge, or discard this patch.