ILIAS  release_8 Revision v8.24
GloPresentationGUIRequestTest Class Reference

Test clipboard repository. More...

+ Inheritance diagram for GloPresentationGUIRequestTest:
+ Collaboration diagram for GloPresentationGUIRequestTest:

Public Member Functions

 testRefId ()
 
 testDefinitionId ()
 
 testLetter ()
 
 testTermId ()
 
 test ()
 

Protected Member Functions

 getRequest (array $get, array $post)
 

Detailed Description

Test clipboard repository.

Author
Alexander Killing killi.nosp@m.ng@l.nosp@m.eifos.nosp@m..de

Definition at line 10 of file GloPresentationGUIRequestTest.php.

Member Function Documentation

◆ getRequest()

GloPresentationGUIRequestTest::getRequest ( array  $get,
array  $post 
)
protected

Definition at line 12 of file GloPresentationGUIRequestTest.php.

13 {
14 $http_mock = $this->createMock(ILIAS\HTTP\Services::class);
15 $lng_mock = $this->createMock(ilLanguage::class);
16 $data = new \ILIAS\Data\Factory();
17 $refinery = new \ILIAS\Refinery\Factory($data, $lng_mock);
18 return new \ILIAS\Glossary\Presentation\PresentationGUIRequest(
19 $http_mock,
21 $get,
22 $post
23 );
24 }
$post
Definition: ltitoken.php:49
Refinery Factory $refinery
Class ChatMainBarProvider \MainMenu\Provider.

References $data, $post, and ILIAS\Repository\$refinery.

Referenced by test(), testDefinitionId(), testLetter(), testRefId(), and testTermId().

+ Here is the caller graph for this function:

◆ test()

GloPresentationGUIRequestTest::test ( )

Definition at line 86 of file GloPresentationGUIRequestTest.php.

86 : void
87 {
88 $request = $this->getRequest(
89 [
90 "type" => "xml"
91 ],
92 []
93 );
94
95 $this->assertEquals(
96 "xml",
97 $request->getExportType()
98 );
99 }

References getRequest().

+ Here is the call graph for this function:

◆ testDefinitionId()

GloPresentationGUIRequestTest::testDefinitionId ( )

Definition at line 41 of file GloPresentationGUIRequestTest.php.

41 : void
42 {
43 $request = $this->getRequest(
44 [
45 "def" => "7"
46 ],
47 []
48 );
49
50 $this->assertEquals(
51 7,
52 $request->getDefinitionId()
53 );
54 }

References getRequest().

+ Here is the call graph for this function:

◆ testLetter()

GloPresentationGUIRequestTest::testLetter ( )

Definition at line 56 of file GloPresentationGUIRequestTest.php.

56 : void
57 {
58 $request = $this->getRequest(
59 [
60 "letter" => "a"
61 ],
62 []
63 );
64
65 $this->assertEquals(
66 "a",
67 $request->getLetter()
68 );
69 }

References getRequest().

+ Here is the call graph for this function:

◆ testRefId()

GloPresentationGUIRequestTest::testRefId ( )

Definition at line 26 of file GloPresentationGUIRequestTest.php.

26 : void
27 {
28 $request = $this->getRequest(
29 [
30 "ref_id" => "5"
31 ],
32 []
33 );
34
35 $this->assertEquals(
36 5,
37 $request->getRefId()
38 );
39 }

References getRequest().

+ Here is the call graph for this function:

◆ testTermId()

GloPresentationGUIRequestTest::testTermId ( )

Definition at line 71 of file GloPresentationGUIRequestTest.php.

71 : void
72 {
73 $request = $this->getRequest(
74 [
75 "term_id" => "14"
76 ],
77 []
78 );
79
80 $this->assertEquals(
81 14,
82 $request->getTermId()
83 );
84 }

References getRequest().

+ Here is the call graph for this function:

The documentation for this class was generated from the following file: