ILIAS
release_9 Revision v9.13-25-g2c18ec4c24f
◀ ilDoc Overview
InfoScreenStandardGUIRequestTest.php
Go to the documentation of this file.
1
<?php
2
3
declare(strict_types=1);
4
5
use
PHPUnit\Framework\TestCase
;
6
use
ILIAS\InfoScreen\StandardGUIRequest
;
7
use
ILIAS\Data\Factory
;
8
14
class
InfoScreenStandardGUIRequestTest
extends
TestCase
15
{
16
protected
function
tearDown
(): void
17
{
18
}
19
20
protected
function
getRequest
(array $get, array
$post
):
StandardGUIRequest
21
{
22
$http_mock = $this->createMock(
ILIAS
\
HTTP
\Services::class);
23
$lng_mock = $this->createMock(ilLanguage::class);
24
$data
=
new
Factory
();
25
$refinery
= new \ILIAS\Refinery\Factory(
$data
, $lng_mock);
26
return
new
StandardGUIRequest
(
27
$http_mock,
28
$refinery
,
29
$get,
30
$post
31
);
32
}
33
37
public
function
testUserId
()
38
{
39
$request = $this->
getRequest
(
40
[
41
"user_id"
=>
"57"
42
],
43
[]
44
);
45
46
$this->assertEquals(
47
57,
48
$request->getUserId()
49
);
50
}
51
55
public
function
testLPEdit
()
56
{
57
$request = $this->
getRequest
(
58
[
59
],
60
[
61
"lp_edit"
=>
"1"
62
]
63
);
64
65
$this->assertEquals(
66
1,
67
$request->getLPEdit()
68
);
69
}
70
}
$data
$data
Definition:
ltiregistration.php:31
InfoScreenStandardGUIRequestTest\testUserId
testUserId()
Test user id.
Definition:
InfoScreenStandardGUIRequestTest.php:37
ILIAS
Class ChatMainBarProvider .
InfoScreenStandardGUIRequestTest\testLPEdit
testLPEdit()
Test lp edit.
Definition:
InfoScreenStandardGUIRequestTest.php:55
HTTP
Factory
Factory
InfoScreenStandardGUIRequestTest\getRequest
getRequest(array $get, array $post)
Definition:
InfoScreenStandardGUIRequestTest.php:20
InfoScreenStandardGUIRequestTest\tearDown
tearDown()
Definition:
InfoScreenStandardGUIRequestTest.php:16
StandardGUIRequest
InfoScreenStandardGUIRequestTest
Test clipboard repository.
Definition:
InfoScreenStandardGUIRequestTest.php:14
ILIAS\InfoScreen\StandardGUIRequest
Definition:
class.StandardGUIRequest.php:27
$post
$post
Definition:
ltitoken.php:49
TestCase
ILIAS\Repository\$refinery
Refinery Factory $refinery
Definition:
trait.BaseGUIRequest.php:36
Services
InfoScreen
test
InfoScreenStandardGUIRequestTest.php
Generated on Wed Sep 10 2025 14:11:30 for ILIAS by
1.8.13 (using
Doxyfile
)