Skip to content

Commit d48009b

Browse files
localheinzsebastianbergmann
authored andcommitted
Fix: Use PHPUnit\TestFixture as namespace for test fixtures
1 parent 35c6ddf commit d48009b

File tree

228 files changed

+892
-506
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

228 files changed

+892
-506
lines changed

tests/_files/3194.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
1012
use PHPUnit\Framework\TestCase;
1113

1214
trait T3194
@@ -28,7 +30,7 @@ public function doSomething(): bool
2830
}
2931

3032
/**
31-
* @covers C3194
33+
* @covers \PHPUnit\TestFixture\C3194
3234
*/
3335
final class Test3194 extends TestCase
3436
{

tests/_files/AbstractMockTestClass.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
1012
abstract class AbstractMockTestClass implements MockTestInterface
1113
{
1214
abstract public function doSomething();

tests/_files/AbstractTest.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
1012
use PHPUnit\Framework\TestCase;
1113

1214
abstract class AbstractTest extends TestCase

tests/_files/AbstractTrait.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
1012
trait AbstractTrait
1113
{
1214
abstract public function doSomething();

tests/_files/AbstractVariousIterableDataProviderTest.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
1012
abstract class AbstractVariousIterableDataProviderTest
1113
{
1214
abstract public function asArrayProvider();

tests/_files/AnInterface.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
1012
interface AnInterface
1113
{
1214
public function doSomething();

tests/_files/AnInterfaceWithReturnType.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
1012
interface AnInterfaceWithReturnType
1113
{
1214
public function returnAnArray(): array;

tests/_files/ArrayAccessible.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,14 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
12+
use function array_key_exists;
13+
use ArrayAccess;
14+
use ArrayIterator;
15+
use IteratorAggregate;
16+
use ReturnTypeWillChange;
17+
1018
class ArrayAccessible implements ArrayAccess, IteratorAggregate
1119
{
1220
private $array;
@@ -19,7 +27,7 @@ public function __construct(array $array = [])
1927
#[ReturnTypeWillChange]
2028
public function offsetExists($offset)
2129
{
22-
return \array_key_exists($offset, $this->array);
30+
return array_key_exists($offset, $this->array);
2331
}
2432

2533
#[ReturnTypeWillChange]

tests/_files/AssertionExample.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,14 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
12+
use function assert;
13+
1014
class AssertionExample
1115
{
1216
public function doSomething(): void
1317
{
14-
\assert(false);
18+
assert(false);
1519
}
1620
}

tests/_files/AssertionExampleTest.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77
* For the full copyright and license information, please view the LICENSE
88
* file that was distributed with this source code.
99
*/
10+
namespace PHPUnit\TestFixture;
11+
1012
use PHPUnit\Framework\TestCase;
1113

1214
class AssertionExampleTest extends TestCase

0 commit comments

Comments
 (0)