mirror of
https://github.com/shlinkio/shlink.git
synced 2026-02-28 04:03:12 +08:00
Update to PHP coding standard 2.4.0
This commit is contained in:
@@ -33,7 +33,7 @@ class DomainServiceTest extends TestCase
|
||||
}
|
||||
|
||||
#[Test, DataProvider('provideExcludedDomains')]
|
||||
public function listDomainsDelegatesIntoRepository(array $domains, array $expectedResult, ?ApiKey $apiKey): void
|
||||
public function listDomainsDelegatesIntoRepository(array $domains, array $expectedResult, ApiKey|null $apiKey): void
|
||||
{
|
||||
$repo = $this->createMock(DomainRepository::class);
|
||||
$repo->expects($this->once())->method('findDomains')->with($apiKey)->willReturn($domains);
|
||||
@@ -124,7 +124,7 @@ class DomainServiceTest extends TestCase
|
||||
}
|
||||
|
||||
#[Test, DataProvider('provideFoundDomains')]
|
||||
public function getOrCreateAlwaysPersistsDomain(?Domain $foundDomain, ?ApiKey $apiKey): void
|
||||
public function getOrCreateAlwaysPersistsDomain(Domain|null $foundDomain, ApiKey|null $apiKey): void
|
||||
{
|
||||
$authority = 'example.com';
|
||||
$repo = $this->createMock(DomainRepository::class);
|
||||
@@ -161,8 +161,10 @@ class DomainServiceTest extends TestCase
|
||||
}
|
||||
|
||||
#[Test, DataProvider('provideFoundDomains')]
|
||||
public function configureNotFoundRedirectsConfiguresFetchedDomain(?Domain $foundDomain, ?ApiKey $apiKey): void
|
||||
{
|
||||
public function configureNotFoundRedirectsConfiguresFetchedDomain(
|
||||
Domain|null $foundDomain,
|
||||
ApiKey|null $apiKey,
|
||||
): void {
|
||||
$authority = 'example.com';
|
||||
$repo = $this->createMock(DomainRepository::class);
|
||||
$repo->method('findOneByAuthority')->with($authority, $apiKey)->willReturn($foundDomain);
|
||||
|
||||
Reference in New Issue
Block a user