@@ -89,6 +89,9 @@ discard block |
||
89 | 89 | protected $contentEncoded; |
90 | 90 | |
91 | 91 | |
92 | + /** |
|
93 | + * @param string $id |
|
94 | + */ |
|
92 | 95 | public function __construct($providerId, $id) { |
93 | 96 | $this->providerId = $providerId; |
94 | 97 | $this->id = $id; |
@@ -506,7 +509,7 @@ discard block |
||
506 | 509 | } |
507 | 510 | |
508 | 511 | /** |
509 | - * @param $excerpt |
|
512 | + * @param string $excerpt |
|
510 | 513 | * |
511 | 514 | * @return mixed |
512 | 515 | */ |
@@ -204,7 +204,7 @@ discard block |
||
204 | 204 | $output->write(' ', true); |
205 | 205 | } |
206 | 206 | |
207 | - $output->write($line . ' ', false); |
|
207 | + $output->write($line.' ', false); |
|
208 | 208 | } |
209 | 209 | |
210 | 210 | |
@@ -254,7 +254,7 @@ discard block |
||
254 | 254 | $this->output($output, 'Testing mocked provider: get indexable documents.'); |
255 | 255 | $indexableDocuments = |
256 | 256 | $testProvider->generateIndexableDocuments(TestService::DOCUMENT_USER1); |
257 | - $this->output($output, '(' . sizeof($indexableDocuments) . ' items)', false); |
|
257 | + $this->output($output, '('.sizeof($indexableDocuments).' items)', false); |
|
258 | 258 | $this->output($output, true); |
259 | 259 | } |
260 | 260 | |
@@ -268,12 +268,12 @@ discard block |
||
268 | 268 | private function testLoadingPlatform($output) { |
269 | 269 | $this->output($output, 'Loading search platform.'); |
270 | 270 | $testPlatform = $this->platformService->getPlatform(); |
271 | - $this->output($output, '(' . $testPlatform->getName() . ')', false); |
|
271 | + $this->output($output, '('.$testPlatform->getName().')', false); |
|
272 | 272 | $this->output($output, true); |
273 | 273 | |
274 | 274 | $this->output($output, 'Testing search platform.'); |
275 | 275 | if (!$testPlatform->testPlatform()) { |
276 | - throw new Exception ('Search platform (' . $testPlatform->getName() . ') down ?'); |
|
276 | + throw new Exception('Search platform ('.$testPlatform->getName().') down ?'); |
|
277 | 277 | } |
278 | 278 | $this->output($output, true); |
279 | 279 | |
@@ -369,13 +369,13 @@ discard block |
||
369 | 369 | ); |
370 | 370 | |
371 | 371 | $this->output( |
372 | - $output, '(size: ' . $indexDocument->getContentSize() . ')', false |
|
372 | + $output, '(size: '.$indexDocument->getContentSize().')', false |
|
373 | 373 | ); |
374 | 374 | $this->output($output, true); |
375 | 375 | } catch (Exception $e) { |
376 | 376 | throw new Exception( |
377 | - "Issue while getting test document '" . TestService::DOCUMENT_TYPE_LICENSE |
|
378 | - . "' from search platform: " . $e->getMessage() |
|
377 | + "Issue while getting test document '".TestService::DOCUMENT_TYPE_LICENSE |
|
378 | + . "' from search platform: ".$e->getMessage() |
|
379 | 379 | ); |
380 | 380 | } |
381 | 381 | |
@@ -549,7 +549,7 @@ discard block |
||
549 | 549 | ) { |
550 | 550 | $this->output( |
551 | 551 | $output, |
552 | - " - '" . $search . "'" . (($moreOutput === '') ? '' : ' - ' . $moreOutput . ' - ') |
|
552 | + " - '".$search."'".(($moreOutput === '') ? '' : ' - '.$moreOutput.' - ') |
|
553 | 553 | ); |
554 | 554 | $request = new SearchRequest(); |
555 | 555 | |
@@ -563,7 +563,7 @@ discard block |
||
563 | 563 | |
564 | 564 | $this->output( |
565 | 565 | $output, |
566 | - '(result: ' . $searchResult->getCount() . ', expected: ' . json_encode($expected) . ')', |
|
566 | + '(result: '.$searchResult->getCount().', expected: '.json_encode($expected).')', |
|
567 | 567 | false |
568 | 568 | ); |
569 | 569 | $this->compareSearchResult($searchResult, $expected); |
@@ -627,12 +627,12 @@ discard block |
||
627 | 627 | private function compareSearchResult(SearchResult $searchResult, $entries) { |
628 | 628 | $documents = $searchResult->getDocuments(); |
629 | 629 | if (sizeof($documents) !== sizeof($entries)) { |
630 | - throw new \Exception('Unexpected SearchResult: ' . json_encode($searchResult)); |
|
630 | + throw new \Exception('Unexpected SearchResult: '.json_encode($searchResult)); |
|
631 | 631 | } |
632 | 632 | |
633 | 633 | foreach ($documents as $document) { |
634 | 634 | if (!in_array($document->getId(), $entries)) { |
635 | - throw new \Exception('Unexpected Document: ' . json_encode($document)); |
|
635 | + throw new \Exception('Unexpected Document: '.json_encode($document)); |
|
636 | 636 | } |
637 | 637 | } |
638 | 638 | } |
@@ -645,7 +645,7 @@ discard block |
||
645 | 645 | * @throws InterruptException |
646 | 646 | */ |
647 | 647 | private function pause(OutputInterface $output, $s) { |
648 | - $this->output($output, 'Pausing ' . $s . ' seconds'); |
|
648 | + $this->output($output, 'Pausing '.$s.' seconds'); |
|
649 | 649 | |
650 | 650 | for ($i = 1; $i <= $s; $i++) { |
651 | 651 | if (time_nanosleep(1, 0) !== true) { |