diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 0255c77..6ff41af 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -12,6 +12,10 @@ jobs: fail-fast: false matrix: php: + - "7.2" + - "7.3" + - "7.4" + - "8.0" - "8.1" - "8.2" - "8.3" diff --git a/composer.json b/composer.json index 7e3923f..15ff22b 100644 --- a/composer.json +++ b/composer.json @@ -23,7 +23,7 @@ }, "extra": { "branch-alias": { - "dev-master": "3.4.x-dev" + "dev-master": "3.x-dev" } } } diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 5c8d487..ab6b545 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -1,7 +1,7 @@ @@ -204,7 +205,14 @@ public function testRawHonorsNullValues() public function testFluentRegister() { $pimple = new Container(); - $this->assertSame($pimple, $pimple->register($this->getMockBuilder('Pimple\ServiceProviderInterface')->getMock())); + + $stub = new class implements ServiceProviderInterface { + public function register(Container $pimple) + { + } + }; + + $this->assertSame($pimple, $pimple->register($stub)); } public function testRawValidatesKeyIsPresent() @@ -275,13 +283,13 @@ public function testExtendDoesNotLeakWithFactories() unset($pimple['foo']); $p = new \ReflectionProperty($pimple, 'values'); - if (PHP_VERSION < 80100) { + if (PHP_VERSION_ID < 80100) { $p->setAccessible(true); } $this->assertEmpty($p->getValue($pimple)); $p = new \ReflectionProperty($pimple, 'factories'); - if (PHP_VERSION < 80100) { + if (PHP_VERSION_ID < 80100) { $p->setAccessible(true); } $this->assertCount(0, $p->getValue($pimple)); @@ -425,6 +433,7 @@ public function testLegacyExtendFailsForKeysNotContainingServiceDefinitions($ser /** * @group legacy * @expectedDeprecation How Pimple behaves when extending protected closures will be fixed in Pimple 4. Are you sure "foo" should be protected? + * @dataProvider badServiceDefinitionProvider */ #[DataProvider('badServiceDefinitionProvider')] public function testExtendingProtectedClosureDeprecation($service)