public function testGetSetAPIUser()
{
$event = new InteractiveLoginEvent(new Request(), $this->getMock('Symfony\\Component\\Security\\Core\\Authentication\\Token\\TokenInterface'));
$this->assertFalse($event->hasAPIUser());
$apiUser = $this->getMock('eZ\\Publish\\API\\Repository\\Values\\User\\User');
$event->setApiUser($apiUser);
$this->assertTrue($event->hasAPIUser());
$this->assertSame($apiUser, $event->getAPIUser());
}