Skip to content

Commit

Permalink
Adding support for PHP 8.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Rimantas Černiauskas authored and pelanis committed Nov 21, 2022
1 parent 59ca2c2 commit 49a9b14
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 13 deletions.
4 changes: 1 addition & 3 deletions Tests/ApiCompilerPassTest.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<?php

declare(strict_types=1);

namespace Paysera\Bundle\RestBundle\Tests;

use Paysera\Bundle\RestBundle\DependencyInjection\Compiler\ApiCompilerPass;
Expand Down Expand Up @@ -32,7 +30,7 @@ class ApiCompilerPassTest extends TestCase
*/
private $apiCompilerPass;

public function setUp()
public function setUp(): void
{
$this->serviceDefinition = new Definition();
$this->resolverDefinition = $this->createMock(Definition::class);
Expand Down
2 changes: 1 addition & 1 deletion Tests/Listener/RestListenerLocaleTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class RestListenerLocaleTest extends TestCase
*/
private $responseEvent;

public function setUp()
public function setUp(): void
{
$this->responseEvent = Mockery::mock(GetResponseEvent::class);
}
Expand Down
2 changes: 1 addition & 1 deletion Tests/Listener/RestListenerPathConverterTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class RestListenerPathConverterTest extends TestCase
*/
private $filterControllerEvent;

public function setUp()
public function setUp(): void
{
$this->filterControllerEvent = Mockery::mock(FilterControllerEvent::class);
}
Expand Down
2 changes: 1 addition & 1 deletion Tests/Listener/RestListenerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ class RestListenerTest extends TestCase

private $storedContext = [];

public function setUp()
public function setUp(): void
{
$this->apiManager = Mockery::mock(ApiManager::class);

Expand Down
2 changes: 1 addition & 1 deletion Tests/RequestApiResolverTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class RequestApiResolverTest extends TestCase
*/
private $requestApiResolver;

protected function setUp()
protected function setUp(): void
{
$this->restApiRegistry = Mockery::mock(RestApiRegistry::class);
$this->apiKeyResolver = Mockery::mock(RequestApiKeyResolver::class);
Expand Down
6 changes: 3 additions & 3 deletions Tests/RestApiTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ class RestApiTest extends TestCase
private $logger;
private $messageStorage = [];
private $controllerKey = 'Key:Key';
public function setUp()

public function setUp(): void
{
$this->serviceContainer = Mockery::mock('Symfony\Component\DependencyInjection\ContainerInterface');

Expand All @@ -33,7 +33,7 @@ public function setUp()
$this->logger = Mockery::mock('Psr\Log\LoggerInterface');
$this->logger->shouldReceive('debug')->andReturnUsing($this->storeMessage());
}

public function controllerKeyProvider()
{
return [
Expand Down
2 changes: 1 addition & 1 deletion Tests/Security/RoleAndIpStrategyTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class RoleAndIpStrategyTest extends TestCase
*/
private $strategy;

public function setUp()
public function setUp(): void
{
/** @var TokenStorageInterface|PHPUnit_Framework_MockObject_MockObject $tokenStorageMock */
$tokenStorageMock = $this->getMockBuilder(TokenStorageInterface::class)->getMock();
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
}
},
"require": {
"php": "^7.0 || ^8.0",
"php": "^7.1 || ^8.0",
"paysera/lib-serializer": "^3.0",
"doctrine/orm": "^2.0",
"symfony/config": "^3.0 || ^4.0",
Expand All @@ -22,7 +22,7 @@
"bin-dir": "bin"
},
"require-dev": {
"phpunit/phpunit": "^6.5",
"phpunit/phpunit": "^8.0",
"mockery/mockery": "^1.2"
}
}

0 comments on commit 49a9b14

Please sign in to comment.