Skip to content

Commit

Permalink
remove phpunit polyfills
Browse files Browse the repository at this point in the history
  • Loading branch information
frederikbosch committed May 16, 2024
1 parent 3d78b7c commit 7941027
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 21 deletions.
1 change: 0 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
},
"require-dev": {
"producer/producer": "^2.3",
"yoast/phpunit-polyfills": "^2.0",
"phpunit/phpunit": "^9.0 || ^10.0",
"phpstan/phpstan": "^1.11.1"
},
Expand Down
4 changes: 2 additions & 2 deletions tests/AbstractContainerConfigTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
*/
namespace Aura\Di;

use Yoast\PHPUnitPolyfills\TestCases\TestCase;
use PHPUnit\Framework\TestCase;

/**
*
Expand Down Expand Up @@ -36,7 +36,7 @@ abstract class AbstractContainerConfigTestCase extends TestCase
* @return null
*
*/
protected function set_up()
protected function setUp(): void
{
$builder = new ContainerBuilder();
$this->di = $builder->newConfiguredInstance(
Expand Down
6 changes: 3 additions & 3 deletions tests/ContainerBuilderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
namespace Aura\Di;

use Aura\Di\Fake\FakeParentClass;
use Yoast\PHPUnitPolyfills\TestCases\TestCase;
use PHPUnit\Framework\TestCase;

class ContainerBuilderTest extends TestCase
{
Expand All @@ -11,9 +11,9 @@ class ContainerBuilderTest extends TestCase
*/
protected $builder;

protected function set_up()
protected function setUp(): void
{
parent::set_up();
parent::setUp();
$this->builder = new ContainerBuilder();
}

Expand Down
7 changes: 3 additions & 4 deletions tests/ContainerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,11 @@
use Aura\Di\Fake\FakeMutationWithDependencyClass;
use Aura\Di\Fake\FakeOtherClass;
use Aura\Di\Fake\FakeParamsClass;
use Aura\Di\Injection\InjectionFactory;
use Aura\Di\Resolver\Blueprint;
use Aura\Di\Resolver\Reflector;
use Aura\Di\Resolver\Resolver;
use PHPUnit\Framework\MockObject\MockObject;
use Yoast\PHPUnitPolyfills\TestCases\TestCase;
use PHPUnit\Framework\TestCase;

class ContainerTest extends TestCase
{
Expand All @@ -24,9 +23,9 @@ class ContainerTest extends TestCase
*/
protected $container;

protected function set_up()
protected function setUp(): void
{
parent::set_up();
parent::setUp();
$this->resolver = new Resolver(new Reflector());
$this->container = new Container($this->resolver);
}
Expand Down
2 changes: 1 addition & 1 deletion tests/Injection/LazyIncludeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

use Aura\Di\Resolver\Reflector;
use Aura\Di\Resolver\Resolver;
use Yoast\PHPUnitPolyfills\TestCases\TestCase;
use PHPUnit\Framework\TestCase;

class LazyIncludeTest extends TestCase
{
Expand Down
2 changes: 1 addition & 1 deletion tests/Injection/LazyRequireTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

use Aura\Di\Resolver\Reflector;
use Aura\Di\Resolver\Resolver;
use Yoast\PHPUnitPolyfills\TestCases\TestCase;
use PHPUnit\Framework\TestCase;

class LazyRequireTest extends TestCase
{
Expand Down
6 changes: 3 additions & 3 deletions tests/ResolutionHelperTest.php
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
<?php
namespace Aura\Di;

use Yoast\PHPUnitPolyfills\TestCases\TestCase;
use PHPUnit\Framework\TestCase;

class ResolutionHelperTest extends TestCase
{
protected $container;

protected $helper;

protected function set_up()
protected function setUp(): void
{
parent::set_up();
parent::setUp();
$this->container = $this->getMockBuilder(Container::class)
->disableOriginalConstructor()
->getMock();
Expand Down
4 changes: 2 additions & 2 deletions tests/Resolver/AutoResolverTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ class AutoResolverTest extends ResolverTest
*/
protected $resolver;

protected function set_up()
protected function setUp(): void
{
parent::set_up();
parent::setUp();
$this->resolver = new AutoResolver(new Reflector());
}

Expand Down
7 changes: 3 additions & 4 deletions tests/Resolver/ResolverTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,9 @@
use Aura\Di\Fake\FakeInterfaceClass1;
use Aura\Di\Fake\FakeInterfaceClass2;
use Aura\Di\Injection\Factory;
use Aura\Di\Injection\InjectionFactory;
use Aura\Di\Injection\Lazy;
use Aura\Di\Injection\LazyGet;
use Yoast\PHPUnitPolyfills\TestCases\TestCase;
use PHPUnit\Framework\TestCase;

class ResolverTest extends TestCase
{
Expand All @@ -16,9 +15,9 @@ class ResolverTest extends TestCase
*/
protected $resolver;

protected function set_up()
protected function setUp(): void
{
parent::set_up();
parent::setUp();
$this->resolver = new Resolver(new Reflector());
}

Expand Down

0 comments on commit 7941027

Please sign in to comment.