Skip to content

Commit e61cf3a

Browse files
derrabusnicolas-grekas
authored andcommitted
Fixed tests on the Security and Form components
1 parent f3253d7 commit e61cf3a

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

Security.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,10 @@ public function __construct(ContainerInterface $container)
3434
$this->container = $container;
3535
}
3636

37-
public function getUser(): ?UserInterface
37+
/**
38+
* @return UserInterface|null
39+
*/
40+
public function getUser()
3841
{
3942
if (!$token = $this->getToken()) {
4043
return null;

Tests/Encoder/EncoderFactoryTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ public function testGetEncoderForEncoderAwareWithClassName()
135135

136136
class SomeUser implements UserInterface
137137
{
138-
public function getRoles()
138+
public function getRoles(): array
139139
{
140140
}
141141

@@ -164,7 +164,7 @@ class EncAwareUser extends SomeUser implements EncoderAwareInterface
164164
{
165165
public $encoderName = 'encoder_name';
166166

167-
public function getEncoderName(): string
167+
public function getEncoderName(): ?string
168168
{
169169
return $this->encoderName;
170170
}

0 commit comments

Comments
 (0)