*/ namespace oat\tao\test\unit\service; use oat\generis\test\TestCase; use oat\tao\model\entryPoint\EntryPointService; class EntryPointServiceTest extends TestCase { /** * @var EntryPointService */ private $service; public function setUp(): void { parent::setUp(); $this->service = require __DIR__ . DIRECTORY_SEPARATOR . 'samples' . DIRECTORY_SEPARATOR . 'entrypoint.conf.php'; } /** * @runInSeparateProcess * @preserveGlobalState disabled */ public function testRemoveEntryPoint() { $options = $this->service->getOptions(); $json = json_encode($options); self::assertEquals( '{"existing":{"passwordreset":{},"deliveryServer":{},"guestaccess":{},"proctoringDelivery":{}},"postlogin":["deliveryServer","backoffice","proctoring","childOrganization","scoreReport","exam","testingLocationList","proctoringDelivery"],"prelogin":["guestaccess","proctoringDelivery"],"new_tag":["proctoringDelivery"]}', $json ); $this->service->removeEntryPoint('proctoringDelivery'); $options = $this->service->getOptions(); $json = json_encode($options); self::assertEquals( '{"existing":{"passwordreset":{},"deliveryServer":{},"guestaccess":{}},"postlogin":["deliveryServer","backoffice","proctoring","childOrganization","scoreReport","exam","testingLocationList"],"prelogin":["guestaccess"],"new_tag":[]}', $json ); } }