ILIAS  trunk Revision v11.0_alpha-1731-gff9cd7e2bd3
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
LSUrlBuilderTest.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
23 
25 {
26  protected LSUrlBuilder $ub;
27 
28  protected function setUp(): void
29  {
30  $data_factory = new Factory();
31  $uri = $data_factory->uri('https://ilias.de/somepath');
32  $this->ub = new LSUrlBuilder($uri);
33  }
34 
35  public function testDataType(): void
36  {
37  $this->assertInstanceOf(ILIAS\Data\URI::class, $this->ub->getURL('x'));
38  }
39 
40  public function testUrlConcatenation(): void
41  {
42  $uri = $this->ub->getURL('command', 123);
43  $expected = LSUrlBuilder::PARAM_LSO_COMMAND . '=command&'
45  $this->assertEquals($expected, $uri->getQuery());
46  }
47 }
Interface Observer Contains several chained tasks and infos about them.
const PARAM_LSO_COMMAND
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
const PARAM_LSO_PARAMETER
Builds data types.
Definition: Factory.php:35