View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0001932 | Xdebug | Code Coverage | public | 2021-01-13 14:00 | 2021-01-23 12:35 |
Reporter | mateusz | Assigned To | derick | ||
Priority | normal | Severity | minor | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Product Version | 3.0.2 | ||||
Target Version | 3.0dev | Fixed in Version | 3.0.3 | ||
Summary | 0001932: One line in multi-line string concatenation is not covered | ||||
Description | One line in multi-line string concatenation is not showed as covered by unit tests. | ||||
Steps To Reproduce |
| ||||
Tags | coverage, error | ||||
Attached Files | Example.php (512 bytes)
<?php namespace Service; class Example { public function executeAction(): bool { $path = $this->getBasicPath() . '/' . $this->getFileName(); return $this->runAction($path); } private function getBasicPath(): string { return '/var/www'; } private function getFileName(): string { return 'file.csv'; } private function runAction(string $path): bool { return true; } } Example.php-v2.php (486 bytes)
<?php namespace Service; class Example { public function executeAction(): bool { $path = $this->getBasicPath() . '/' . $this->getFileName(); return $this->runAction($path); } private function getBasicPath(): string { return '/var/www'; } private function getFileName(): string { return 'file.csv'; } private function runAction(string $path): bool { return true; } } ExampleTest.php (395 bytes)
<?php namespace Test; use PHPUnit\Framework\TestCase; use Service\Example; class ExampleTest extends TestCase { private $testObject; public function setUp(): void { $this->testObject = new Example(); } public function testExecuteAction() { $result = $this->testObject->executeAction(); $this->assertTrue($result); } } | ||||
Operating System | Ubuntu | ||||
PHP Version | 7.3.20-7.3.29 | ||||
Date Modified | Username | Field | Change |
---|---|---|---|
2021-01-13 14:00 | mateusz | New Issue | |
2021-01-13 14:00 | mateusz | Tag Attached: coverage | |
2021-01-13 14:00 | mateusz | Tag Attached: error | |
2021-01-13 14:00 | mateusz | File Added: Example.php | |
2021-01-13 14:00 | mateusz | File Added: Example.php-v2.php | |
2021-01-13 14:00 | mateusz | File Added: ExampleTest.php | |
2021-01-20 11:50 | derick | Assigned To | => derick |
2021-01-20 11:50 | derick | Status | new => confirmed |
2021-01-20 11:50 | derick | Target Version | => 3.0dev |
2021-01-20 11:50 | derick | Description Updated | |
2021-01-20 11:50 | derick | Steps to Reproduce Updated | |
2021-01-22 15:26 | derick | Summary | One line in multi-line string concatenation is not showed as covered by unit tests => One line in multi-line string concatenation is not covered |
2021-01-22 15:26 | derick | Note Added: 0005650 | |
2021-01-23 12:35 | derick | Status | confirmed => closed |
2021-01-23 12:35 | derick | Resolution | open => fixed |
2021-01-23 12:35 | derick | Fixed in Version | => 3.0.3 |