/**
* @group MagicSwitchFactory
* @covers FOF30\Factory\MagicSwitchFactory::transparentAuthentication
* @dataProvider MagicSwitchFactoryDataprovider::getTestTransparentAuthentication
*/
public function testTransparentAuthentication($test, $check)
{
$msg = 'MagicSwitchFactory::transparentAuthentication %s - Case: ' . $check['case'];
$container = new TestContainer(array('componentName' => $test['component'], 'backEndPath' => $test['backend_path']));
$platform = $container->platform;
$platform::$isAdmin = $test['backend'];
// Required so we force FOF to read the fof.xml file
$dummy = $container->appConfig;
$factory = new MagicSwitchFactory($container);
$result = $factory->transparentAuthentication();
$this->assertEquals($check['result'], get_class($result), sprintf($msg, 'Returned the wrong result'));
}