Skip to content

Commit 1667b7d

Browse files
Revert "Fix CS/WS issues"
This reverts commit dd00e10.
1 parent 8fb2b32 commit 1667b7d

File tree

7 files changed

+19
-53
lines changed

7 files changed

+19
-53
lines changed
Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,7 @@
11
<?php
22

33
declare(strict_types=1);
4-
/*
5-
* This file is part of PHPUnit.
6-
*
7-
* (c) Sebastian Bergmann <[email protected]>
8-
*
9-
* For the full copyright and license information, please view the LICENSE
10-
* file that was distributed with this source code.
11-
*/
12-
require_once __DIR__ . '/src/Method.php';
134

14-
require_once __DIR__ . '/src/FullyTestedClass.php';
15-
16-
require_once __DIR__ . '/src/functions.php';
5+
require_once __DIR__.'/src/Method.php';
6+
require_once __DIR__.'/src/FullyTestedClass.php';
7+
require_once __DIR__.'/src/functions.php';

tests/end-to-end/code-coverage/code-coverage/src/FullyTestedClass.php

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,8 @@
11
<?php
22

33
declare(strict_types=1);
4-
/*
5-
* This file is part of PHPUnit.
6-
*
7-
* (c) Sebastian Bergmann <[email protected]>
8-
*
9-
* For the full copyright and license information, please view the LICENSE
10-
* file that was distributed with this source code.
11-
*/
12-
namespace PHPUnit\TestFixture\CodeCoverage;
134

5+
namespace PHPUnit\TestFixture\CodeCoverage;
146
/*
157
* This file is part of PHPUnit.
168
*

tests/end-to-end/code-coverage/code-coverage/src/Method.php

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
* For the full copyright and license information, please view the LICENSE
1010
* file that was distributed with this source code.
1111
*/
12+
1213
namespace PHPUnit\TestFixture\CodeCoverage;
1314

1415
final class Method
@@ -18,13 +19,13 @@ public function greet(): string
1819
return $this->internalMethod();
1920
}
2021

21-
public function unusedPublicMethod(): string
22+
private function internalMethod(): string
2223
{
23-
return 'never returned';
24+
return 'Hello, World!';
2425
}
2526

26-
private function internalMethod(): string
27+
public function unusedPublicMethod(): string
2728
{
28-
return 'Hello, World!';
29+
return 'never returned';
2930
}
3031
}

tests/end-to-end/code-coverage/code-coverage/src/functions.php

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,7 @@
11
<?php
22

33
declare(strict_types=1);
4-
/*
5-
* This file is part of PHPUnit.
6-
*
7-
* (c) Sebastian Bergmann <[email protected]>
8-
*
9-
* For the full copyright and license information, please view the LICENSE
10-
* file that was distributed with this source code.
11-
*/
4+
125
namespace PHPUnit\TestFixture\CodeCoverage;
136

147
/*
@@ -20,11 +13,13 @@
2013
* file that was distributed with this source code.
2114
*/
2215

16+
2317
function fixture_for_phpunit_code_coverage(): bool
2418
{
2519
return true;
2620
}
2721

22+
2823
function fixture_for_phpunit_code_coverage_not_called(): bool
2924
{
3025
return false;

tests/end-to-end/code-coverage/code-coverage/tests/FullyTestedClassTest.php

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,7 @@
11
<?php
22

33
declare(strict_types=1);
4-
/*
5-
* This file is part of PHPUnit.
6-
*
7-
* (c) Sebastian Bergmann <[email protected]>
8-
*
9-
* For the full copyright and license information, please view the LICENSE
10-
* file that was distributed with this source code.
11-
*/
4+
125
namespace PHPUnit\TestFixture\CodeCoverage;
136

147
/*
@@ -21,10 +14,9 @@
2114
*/
2215

2316
use PHPUnit\Framework\Attributes\CoversClass;
24-
use PHPUnit\Framework\TestCase;
2517

26-
#[CoversClass(FullyTestedClass::class)]
27-
class FullyTestedClassTest extends TestCase
18+
#[CoversClass(\PHPUnit\TestFixture\CodeCoverage\FullyTestedClass::class)]
19+
class FullyTestedClassTest extends \PHPUnit\Framework\TestCase
2820
{
2921
public function testMethod(): void
3022
{

tests/end-to-end/code-coverage/code-coverage/tests/FunctionTest.php

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,7 @@
11
<?php
22

33
declare(strict_types=1);
4-
/*
5-
* This file is part of PHPUnit.
6-
*
7-
* (c) Sebastian Bergmann <[email protected]>
8-
*
9-
* For the full copyright and license information, please view the LICENSE
10-
* file that was distributed with this source code.
11-
*/
4+
125
namespace PHPUnit\TestFixture\CodeCoverage;
136

147
/*
@@ -20,6 +13,7 @@
2013
* file that was distributed with this source code.
2114
*/
2215

16+
2317
use PHPUnit\Framework\Attributes\CoversFunction;
2418
use PHPUnit\Framework\TestCase;
2519

tests/end-to-end/code-coverage/code-coverage/tests/MethodTest.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,13 @@
99
* For the full copyright and license information, please view the LICENSE
1010
* file that was distributed with this source code.
1111
*/
12+
1213
namespace PHPUnit\TestFixture\CodeCoverage;
1314

1415
use PHPUnit\Framework\Attributes\CoversClass;
1516
use PHPUnit\Framework\TestCase;
1617

17-
#[CoversClass(Method::class)]
18+
#[CoversClass(\PHPUnit\TestFixture\CodeCoverage\Method::class)]
1819
final class MethodTest extends TestCase
1920
{
2021
public function testMethod(): void

0 commit comments

Comments
 (0)