ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
BookManStandardGUIRequestTest Class Reference
+ Inheritance diagram for BookManStandardGUIRequestTest:
+ Collaboration diagram for BookManStandardGUIRequestTest:

Public Member Functions

 testRefId ()
 
 testPoolRefId ()
 
 testReservationIds ()
 

Protected Member Functions

 tearDown ()
 
 getRequest (array $get, array $post)
 

Detailed Description

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

Definition at line 24 of file BookManStandardGUIRequestTest.php.

Member Function Documentation

◆ getRequest()

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

Definition at line 32 of file BookManStandardGUIRequestTest.php.

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

Referenced by testPoolRefId(), testRefId(), and testReservationIds().

33  {
34  $http_mock = $this->createMock(ILIAS\HTTP\Services::class);
35  $lng_mock = $this->createMock(ilLanguage::class);
36  $data = new \ILIAS\Data\Factory();
37  $refinery = new \ILIAS\Refinery\Factory($data, $lng_mock);
38  return new \ILIAS\BookingManager\StandardGUIRequest(
39  $http_mock,
40  $refinery,
41  $get,
42  $post
43  );
44  }
Class ChatMainBarProvider .
$post
Definition: ltitoken.php:49
Refinery Factory $refinery
+ Here is the caller graph for this function:

◆ tearDown()

BookManStandardGUIRequestTest::tearDown ( )
protected

Definition at line 28 of file BookManStandardGUIRequestTest.php.

28  : void
29  {
30  }

◆ testPoolRefId()

BookManStandardGUIRequestTest::testPoolRefId ( )

Definition at line 61 of file BookManStandardGUIRequestTest.php.

References getRequest().

61  : void
62  {
63  $request = $this->getRequest(
64  [
65  "pool_ref_id" => "6"
66  ],
67  []
68  );
69 
70  $this->assertEquals(
71  6,
72  $request->getPoolRefId()
73  );
74  }
+ Here is the call graph for this function:

◆ testRefId()

BookManStandardGUIRequestTest::testRefId ( )

Definition at line 46 of file BookManStandardGUIRequestTest.php.

References getRequest().

46  : void
47  {
48  $request = $this->getRequest(
49  [
50  "ref_id" => "5"
51  ],
52  []
53  );
54 
55  $this->assertEquals(
56  5,
57  $request->getRefId()
58  );
59  }
+ Here is the call graph for this function:

◆ testReservationIds()

BookManStandardGUIRequestTest::testReservationIds ( )

Definition at line 76 of file BookManStandardGUIRequestTest.php.

References getRequest().

76  : void
77  {
78  $request = $this->getRequest(
79  [
80  ],
81  [
82  "reservation_id" => ["4", "6", "8"]
83  ]
84  );
85 
86  $this->assertEquals(
87  [4, 6, 8],
88  $request->getReservationIds()
89  );
90  }
+ Here is the call graph for this function:

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