@@ -28,6 +28,9 @@ |
||
28 | 28 | return $config->setSrcDir($this->srcDir)->addCloverXmlPath($this->cloverXmlPath); |
29 | 29 | } |
30 | 30 | |
31 | + /** |
|
32 | + * @param Configuration $config |
|
33 | + */ |
|
31 | 34 | protected function createCiEnvVarsCollector($config = null) |
32 | 35 | { |
33 | 36 | if ($config === null) { |
@@ -133,6 +133,9 @@ discard block |
||
133 | 133 | |
134 | 134 | // custom assert |
135 | 135 | |
136 | + /** |
|
137 | + * @param string $runAt |
|
138 | + */ |
|
136 | 139 | protected function assertJsonFile($jsonFile, $serviceName, $serviceJobId, $repoToken, $git, $runAt) |
137 | 140 | { |
138 | 141 | $this->assertEquals($serviceName, $jsonFile->getServiceName()); |
@@ -142,6 +145,12 @@ discard block |
||
142 | 145 | $this->assertEquals($runAt, $jsonFile->getRunAt()); |
143 | 146 | } |
144 | 147 | |
148 | + /** |
|
149 | + * @param string $name |
|
150 | + * @param string $path |
|
151 | + * @param integer $fileLines |
|
152 | + * @param string $source |
|
153 | + */ |
|
145 | 154 | protected function assertSourceFile(SourceFile $sourceFile, $name, $path, $fileLines, array $coverage, $source) |
146 | 155 | { |
147 | 156 | $this->assertEquals($name, $sourceFile->getName()); |
@@ -42,6 +42,9 @@ discard block |
||
42 | 42 | return $this->getMock($class); |
43 | 43 | } |
44 | 44 | |
45 | + /** |
|
46 | + * @return GitCommand |
|
47 | + */ |
|
45 | 48 | protected function createGitCommandStubWith($getBranchesValue, $getHeadCommitValue, $getRemotesValue) |
46 | 49 | { |
47 | 50 | $stub = $this->createGitCommandStub(); |
@@ -53,6 +56,11 @@ discard block |
||
53 | 56 | return $stub; |
54 | 57 | } |
55 | 58 | |
59 | + /** |
|
60 | + * @param string[] $getBranchesValue |
|
61 | + * |
|
62 | + * @return GitCommand |
|
63 | + */ |
|
56 | 64 | protected function createGitCommandStubCalledBranches($getBranchesValue, $getHeadCommitValue, $getRemotesValue) |
57 | 65 | { |
58 | 66 | $stub = $this->createGitCommandStub(); |
@@ -64,6 +72,9 @@ discard block |
||
64 | 72 | return $stub; |
65 | 73 | } |
66 | 74 | |
75 | + /** |
|
76 | + * @return GitCommand |
|
77 | + */ |
|
67 | 78 | protected function createGitCommandStubCalledHeadCommit($getBranchesValue, $getHeadCommitValue, $getRemotesValue) |
68 | 79 | { |
69 | 80 | $stub = $this->createGitCommandStub(); |
@@ -192,6 +192,10 @@ discard block |
||
192 | 192 | return $api; |
193 | 193 | } |
194 | 194 | |
195 | + /** |
|
196 | + * @param integer $statusCode |
|
197 | + * @param string $reasonPhrase |
|
198 | + */ |
|
195 | 199 | protected function createResponseMock($statusCode, $reasonPhrase, $body) |
196 | 200 | { |
197 | 201 | $json = is_array($body) ? json_encode($body) : $body; |
@@ -220,6 +224,9 @@ discard block |
||
220 | 224 | return $response; |
221 | 225 | } |
222 | 226 | |
227 | + /** |
|
228 | + * @return \Psr\Log\LoggerInterface |
|
229 | + */ |
|
223 | 230 | protected function createLoggerMock() |
224 | 231 | { |
225 | 232 | $logger = $this->getMock('Psr\Log\NullLogger', array('info', 'error')); |
@@ -239,6 +246,9 @@ discard block |
||
239 | 246 | |
240 | 247 | // dependent object |
241 | 248 | |
249 | + /** |
|
250 | + * @param integer $percent |
|
251 | + */ |
|
242 | 252 | protected function createCoverage($percent) |
243 | 253 | { |
244 | 254 | // percent = (covered / stmt) * 100; |
@@ -4,6 +4,9 @@ |
||
4 | 4 | |
5 | 5 | class ProjectTestCase extends \PHPUnit_Framework_TestCase |
6 | 6 | { |
7 | + /** |
|
8 | + * @param string $projectDir |
|
9 | + */ |
|
7 | 10 | protected function setUpDir($projectDir) |
8 | 11 | { |
9 | 12 | $this->rootDir = realpath($projectDir . '/prj'); |
@@ -638,7 +638,7 @@ |
||
638 | 638 | * |
639 | 639 | * @param bool $asDom Whether to return a DOM or an XML string |
640 | 640 | * |
641 | - * @return string|\DOMDocument An XML string representing the command |
|
641 | + * @return string An XML string representing the command |
|
642 | 642 | * |
643 | 643 | * @deprecated since version 2.3, to be removed in 3.0. |
644 | 644 | */ |
@@ -41,14 +41,14 @@ discard block |
||
41 | 41 | * Asks the user to select a value. |
42 | 42 | * |
43 | 43 | * @param OutputInterface $output An Output instance |
44 | - * @param string|array $question The question to ask |
|
45 | - * @param array $choices List of choices to pick from |
|
44 | + * @param string $question The question to ask |
|
45 | + * @param string[] $choices List of choices to pick from |
|
46 | 46 | * @param bool|string $default The default answer if the user enters nothing |
47 | 47 | * @param bool|int $attempts Max number of times to ask before giving up (false by default, which means infinite) |
48 | 48 | * @param string $errorMessage Message which will be shown if invalid value from choice list would be picked |
49 | 49 | * @param bool $multiselect Select more than one value separated by comma |
50 | 50 | * |
51 | - * @return int|string|array The selected value or values (the key of the choices array) |
|
51 | + * @return string The selected value or values (the key of the choices array) |
|
52 | 52 | * |
53 | 53 | * @throws InvalidArgumentException |
54 | 54 | */ |
@@ -239,7 +239,7 @@ discard block |
||
239 | 239 | * The question will be asked until the user answers by nothing, yes, or no. |
240 | 240 | * |
241 | 241 | * @param OutputInterface $output An Output instance |
242 | - * @param string|array $question The question to ask |
|
242 | + * @param string $question The question to ask |
|
243 | 243 | * @param bool $default The default answer if the user enters nothing |
244 | 244 | * |
245 | 245 | * @return bool true if the user has confirmed, false otherwise |
@@ -336,13 +336,13 @@ discard block |
||
336 | 336 | * otherwise. |
337 | 337 | * |
338 | 338 | * @param OutputInterface $output An Output instance |
339 | - * @param string|array $question The question to ask |
|
339 | + * @param string $question The question to ask |
|
340 | 340 | * @param callable $validator A PHP callback |
341 | 341 | * @param int|false $attempts Max number of times to ask before giving up (false by default, which means infinite) |
342 | 342 | * @param string $default The default answer if none is given by the user |
343 | 343 | * @param array $autocomplete List of values to autocomplete |
344 | 344 | * |
345 | - * @return mixed |
|
345 | + * @return string |
|
346 | 346 | * |
347 | 347 | * @throws \Exception When any of the validators return an error |
348 | 348 | */ |
@@ -401,7 +401,7 @@ discard block |
||
401 | 401 | /** |
402 | 402 | * Returns the helper's input stream. |
403 | 403 | * |
404 | - * @return resource|null The input stream or null if the default STDIN is used |
|
404 | + * @return resource The input stream or null if the default STDIN is used |
|
405 | 405 | */ |
406 | 406 | public function getInputStream() |
407 | 407 | { |
@@ -141,6 +141,9 @@ discard block |
||
141 | 141 | return isset(self::$formats[$name]) ? self::$formats[$name] : null; |
142 | 142 | } |
143 | 143 | |
144 | + /** |
|
145 | + * @param string $message |
|
146 | + */ |
|
144 | 147 | public function setMessage($message, $name = 'message') |
145 | 148 | { |
146 | 149 | $this->messages[$name] = $message; |
@@ -315,7 +318,7 @@ discard block |
||
315 | 318 | /** |
316 | 319 | * Sets the redraw frequency. |
317 | 320 | * |
318 | - * @param int|float $freq The frequency in steps |
|
321 | + * @param integer $freq The frequency in steps |
|
319 | 322 | */ |
320 | 323 | public function setRedrawFrequency($freq) |
321 | 324 | { |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | * @param OutputInterface $output |
37 | 37 | * @param string|null $format Indicator format |
38 | 38 | * @param int $indicatorChangeInterval Change interval in milliseconds |
39 | - * @param array|null $indicatorValues Animated indicator characters |
|
39 | + * @param string[] $indicatorValues Animated indicator characters |
|
40 | 40 | */ |
41 | 41 | public function __construct(OutputInterface $output, $format = null, $indicatorChangeInterval = 100, $indicatorValues = null) |
42 | 42 | { |
@@ -113,7 +113,7 @@ discard block |
||
113 | 113 | /** |
114 | 114 | * Starts the indicator output. |
115 | 115 | * |
116 | - * @param $message |
|
116 | + * @param string $message |
|
117 | 117 | */ |
118 | 118 | public function start($message) |
119 | 119 | { |
@@ -159,7 +159,7 @@ discard block |
||
159 | 159 | /** |
160 | 160 | * Finish the indicator with message. |
161 | 161 | * |
162 | - * @param $message |
|
162 | + * @param string $message |
|
163 | 163 | */ |
164 | 164 | public function finish($message) |
165 | 165 | { |