ILIAS  trunk Revision v11.0_alpha-1753-gb21ca8c4367
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
URLBuilderTokenTest.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
21 namespace ILIAS\UI;
22 
24 
25 class URLBuilderTokenTest extends TestCase
26 {
27  public function testConstruct(): void
28  {
29  $token = new URLBuilderToken(['test'], 'foo');
30  $this->assertInstanceOf(URLBuilderToken::class, $token);
31  $this->assertIsString($token->getToken());
32  $this->assertNotEmpty($token->getToken());
33  }
34 
35  public function testTokenLength(): void
36  {
37  $token = new URLBuilderToken(['test'], 'foo');
38  $this->assertEquals(URLBuilderToken::TOKEN_LENGTH, strlen($token->getToken()));
39  }
40 
41  public function testTokenName(): void
42  {
43  $token = new URLBuilderToken(['test'], 'foo');
44  $this->assertEquals('test_foo', $token->getName());
45  }
46 }
$token
Definition: xapitoken.php:70
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...