mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-21 15:13:50 +00:00
cs: Fix code style (safe rules only).
This commit is contained in:
@@ -1,5 +1,12 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Chill is a software for social workers
|
||||
*
|
||||
* For the full copyright and license information, please view
|
||||
* the LICENSE file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Chill\MainBundle\Tests\Security\Resolver;
|
||||
|
||||
use Chill\MainBundle\Entity\HasScopeInterface;
|
||||
@@ -8,6 +15,10 @@ use Chill\MainBundle\Entity\Scope;
|
||||
use Chill\MainBundle\Security\Resolver\DefaultScopeResolver;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
/**
|
||||
* @internal
|
||||
* @coversNothing
|
||||
*/
|
||||
class DefaultScopeResolverTest extends TestCase
|
||||
{
|
||||
private DefaultScopeResolver $scopeResolver;
|
||||
@@ -21,8 +32,8 @@ class DefaultScopeResolverTest extends TestCase
|
||||
{
|
||||
$scope = new Scope();
|
||||
$entity = new class($scope) implements HasScopeInterface {
|
||||
|
||||
public function __construct(Scope $scope) {
|
||||
public function __construct(Scope $scope)
|
||||
{
|
||||
$this->scope = $scope;
|
||||
}
|
||||
|
||||
@@ -30,7 +41,6 @@ class DefaultScopeResolverTest extends TestCase
|
||||
{
|
||||
return $this->scope;
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
$this->assertTrue($this->scopeResolver->supports($entity));
|
||||
@@ -41,8 +51,8 @@ class DefaultScopeResolverTest extends TestCase
|
||||
public function testHasScopesInterface()
|
||||
{
|
||||
$entity = new class($scopeA = new Scope(), $scopeB = new Scope()) implements HasScopesInterface {
|
||||
|
||||
public function __construct(Scope $scopeA, Scope $scopeB) {
|
||||
public function __construct(Scope $scopeA, Scope $scopeB)
|
||||
{
|
||||
$this->scopes = [$scopeA, $scopeB];
|
||||
}
|
||||
|
||||
@@ -58,5 +68,4 @@ class DefaultScopeResolverTest extends TestCase
|
||||
$this->assertSame($scopeA, $this->scopeResolver->resolveScope($entity)[0]);
|
||||
$this->assertSame($scopeB, $this->scopeResolver->resolveScope($entity)[1]);
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user