Skip to content

Commit 24097c8

Browse files
committed
Fix Serializable deprecations triggered by token mocks
1 parent 182442c commit 24097c8

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

Tests/Fixtures/TokenInterface.php

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<?php
2+
3+
namespace Symfony\Bundle\FrameworkBundle\Tests\Fixtures;
4+
5+
use Symfony\Component\Security\Core\Authentication\Token\TokenInterface as BaseTokenInterface;
6+
7+
interface TokenInterface extends BaseTokenInterface
8+
{
9+
public function __serialize(): array;
10+
public function __unserialize(array $data): void;
11+
}

Tests/Templating/GlobalVariablesTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@
1212
namespace Symfony\Bundle\FrameworkBundle\Tests\Templating;
1313

1414
use Symfony\Bundle\FrameworkBundle\Templating\GlobalVariables;
15+
use Symfony\Bundle\FrameworkBundle\Tests\Fixtures\TokenInterface;
1516
use Symfony\Bundle\FrameworkBundle\Tests\TestCase;
1617
use Symfony\Component\DependencyInjection\Container;
1718
use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface;
18-
use Symfony\Component\Security\Core\Authentication\Token\TokenInterface;
1919
use Symfony\Component\Security\Core\User\UserInterface;
2020

2121
/**

0 commit comments

Comments
 (0)