ILIAS  release_8 Revision v8.24
ContentStyleStandardGUIRequestTest Class Reference

Test clipboard repository. More...

+ Inheritance diagram for ContentStyleStandardGUIRequestTest:
+ Collaboration diagram for ContentStyleStandardGUIRequestTest:

Public Member Functions

 testRefId ()
 
 testTemplateId ()
 
 testCharacteristics ()
 

Protected Member Functions

 tearDown ()
 
 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 14 of file ContentStyleStandardGUIRequestTest.php.

Member Function Documentation

◆ getRequest()

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

Definition at line 20 of file ContentStyleStandardGUIRequestTest.php.

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,
29 $get,
30 $post
31 );
32 }
Builds data types.
Definition: Factory.php:21
$post
Definition: ltitoken.php:49
Refinery Factory $refinery
Class ChatMainBarProvider \MainMenu\Provider.

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

Referenced by testCharacteristics(), testRefId(), and testTemplateId().

+ Here is the caller graph for this function:

◆ tearDown()

ContentStyleStandardGUIRequestTest::tearDown ( )
protected

Definition at line 16 of file ContentStyleStandardGUIRequestTest.php.

16 : void
17 {
18 }

◆ testCharacteristics()

ContentStyleStandardGUIRequestTest::testCharacteristics ( )

Definition at line 65 of file ContentStyleStandardGUIRequestTest.php.

65 : void
66 {
67 $request = $this->getRequest(
68 [
69 ],
70 [
71 "char" => [
72 "Foo",
73 "Bar"
74 ]
75 ]
76 );
77
78 $this->assertEquals(
79 ["Foo", "Bar"],
80 $request->getCharacteristics()
81 );
82 }

References getRequest().

+ Here is the call graph for this function:

◆ testRefId()

ContentStyleStandardGUIRequestTest::testRefId ( )

Definition at line 34 of file ContentStyleStandardGUIRequestTest.php.

34 : void
35 {
36 $request = $this->getRequest(
37 [
38 "ref_id" => "5"
39 ],
40 []
41 );
42
43 $this->assertEquals(
44 5,
45 $request->getRefId()
46 );
47 }

References getRequest().

+ Here is the call graph for this function:

◆ testTemplateId()

ContentStyleStandardGUIRequestTest::testTemplateId ( )

Definition at line 50 of file ContentStyleStandardGUIRequestTest.php.

50 : void
51 {
52 $request = $this->getRequest(
53 [
54 "t_id" => "7"
55 ],
56 []
57 );
58
59 $this->assertEquals(
60 7,
61 $request->getTemplateId()
62 );
63 }

References getRequest().

+ Here is the call graph for this function:

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