$this->
assertEquals([ 'ROLE_ADMIN' =>
['ROLE_USER'
],
'ROLE_SUPER_ADMIN' =>
['ROLE_USER', 'ROLE_ADMIN', 'ROLE_ALLOWED_TO_SWITCH'
],
'ROLE_REMOTE' =>
['ROLE_USER', 'ROLE_ADMIN'
],
],
$container->
getParameter('security.role_hierarchy.roles'
));
} public function testUserProviders() { $container =
$this->
getContainer('container1'
);
$providers =
array_values(array_filter($container->
getServiceIds(),
fn ($key) =>
str_starts_with($key, 'security.user.provider.concrete'
)));
$expectedProviders =
[ 'security.user.provider.concrete.default',
'security.user.provider.concrete.digest',
'security.user.provider.concrete.basic',
'security.user.provider.concrete.service',
'security.user.provider.concrete.chain',
];
$this->
assertEquals([],
array_diff($expectedProviders,
$providers));
$this->
assertEquals([],
array_diff($providers,
$expectedProviders));