Fix tests and move to 7.3 as a min php version

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2022-03-22 15:07:42 +01:00
parent f840bbba11
commit 490cfb2396
4 changed files with 984 additions and 899 deletions

View File

@@ -13,7 +13,7 @@ jobs:
strategy: strategy:
matrix: matrix:
php-versions: ['7.2', '7.3', '7.4'] php-versions: ['7.3', '7.4']
name: php${{ matrix.php-versions }} lint name: php${{ matrix.php-versions }} lint
steps: steps:

View File

@@ -13,14 +13,17 @@
}, },
"require-dev": { "require-dev": {
"roave/security-advisories": "dev-master", "roave/security-advisories": "dev-master",
"christophwurst/nextcloud": "^21@dev", "christophwurst/nextcloud": "^22@dev",
"phpunit/phpunit": "^9", "phpunit/phpunit": "^8",
"nextcloud/coding-standard": "^0.5.0", "nextcloud/coding-standard": "^0.5.0",
"symfony/event-dispatcher": "^4.0", "symfony/event-dispatcher": "^4.0",
"vimeo/psalm": "^4.3", "vimeo/psalm": "^4.3",
"php-parallel-lint/php-parallel-lint": "^1.2" "php-parallel-lint/php-parallel-lint": "^1.2"
}, },
"config": { "config": {
"platform": {
"php": "7.3"
},
"optimize-autoloader": true, "optimize-autoloader": true,
"classmap-authoritative": true "classmap-authoritative": true
}, },

1868
composer.lock generated

File diff suppressed because it is too large Load Diff

View File

@@ -263,6 +263,9 @@ class BoardServiceTest extends TestCase {
->willReturn([ ->willReturn([
'admin' => 'admin', 'admin' => 'admin',
]); ]);
$this->boardMapper->expects($this->once())
->method('find')
->willReturn(new Board());
$this->assertEquals($acl, $this->service->addAcl( $this->assertEquals($acl, $this->service->addAcl(
123, 'user', 'admin', true, true, true 123, 'user', 'admin', true, true, true
)); ));
@@ -352,6 +355,9 @@ class BoardServiceTest extends TestCase {
$acl->resolveRelation('participant', function ($participant) use (&$user) { $acl->resolveRelation('participant', function ($participant) use (&$user) {
return null; return null;
}); });
$this->boardMapper->expects($this->once())
->method('find')
->willReturn(new Board());
$this->permissionService->expects($this->any()) $this->permissionService->expects($this->any())
->method('findUsers') ->method('findUsers')
->willReturn([ ->willReturn([