ILIAS  trunk Revision v11.0_alpha-1715-g7fc467680fb
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
TableTestBase Class Reference

Basic Tests for all Tables. More...

+ Inheritance diagram for TableTestBase:
+ Collaboration diagram for TableTestBase:

Protected Member Functions

 buildFieldFactory ()
 
 buildRefinery ()
 
 getViewControlFactory ()
 
 getViewControlContainerFactory ()
 
 getTableFactory ()
 
 getMockStorage ()
 

Detailed Description

Basic Tests for all Tables.

Definition at line 34 of file TableTestBase.php.

Member Function Documentation

◆ buildFieldFactory()

TableTestBase::buildFieldFactory ( )
protected

Definition at line 36 of file TableTestBase.php.

References buildRefinery(), and getLanguage().

Referenced by getViewControlFactory().

36  : FieldFactory
37  {
38  return new FieldFactory(
39  $this->createMock(UploadLimitResolver::class),
40  new C\SignalGenerator(),
41  new \ILIAS\Data\Factory(),
42  $this->buildRefinery(),
43  $this->getLanguage()
44  );
45  }
Interface Observer Contains several chained tasks and infos about them.
getLanguage()
Builds data types.
Definition: Factory.php:35
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ buildRefinery()

TableTestBase::buildRefinery ( )
protected

Definition at line 47 of file TableTestBase.php.

Referenced by buildFieldFactory(), and getViewControlFactory().

47  : Refinery
48  {
49  return new Refinery(
50  new \ILIAS\Data\Factory(),
51  $this->createMock(ILIAS\Language\Language::class)
52  );
53  }
Interface Observer Contains several chained tasks and infos about them.
Builds data types.
Definition: Factory.php:35
+ Here is the caller graph for this function:

◆ getMockStorage()

TableTestBase::getMockStorage ( )
protected

Definition at line 89 of file TableTestBase.php.

References $data, and null.

Referenced by getTableFactory(), and DataTest\testDataTableWithIdAndStorage().

89  : ArrayAccess
90  {
91  return new class () implements ArrayAccess {
92  protected array $data = [];
93  public function offsetExists(mixed $offset): bool
94  {
95  return isset($this->data[$offset]);
96  }
97  public function offsetGet(mixed $offset): mixed
98  {
99  if(!$this->offsetExists($offset)) {
100  return null;
101  }
102  return $this->data[$offset];
103  }
104  public function offsetSet(mixed $offset, mixed $value): void
105  {
106  $this->data[$offset] = $value;
107  }
108  public function offsetUnset(mixed $offset): void
109  {
110  unset($this->data[$offset]);
111  }
112  };
113  }
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
+ Here is the caller graph for this function:

◆ getTableFactory()

TableTestBase::getTableFactory ( )
protected

Definition at line 74 of file TableTestBase.php.

References getLanguage(), getMockStorage(), getViewControlContainerFactory(), and getViewControlFactory().

Referenced by DataViewControlsTest\getTable(), DataTest\getTable(), DataTest\testDataTableActions(), DataTest\testDataTableBasicConstruction(), DataTest\testDataTableColumns(), DataTest\testDataTableConstructionWithErrorColumns(), DataTest\testDataTableConstructionWithoutColumns(), DataViewControlsTest\testDataTableHasNoFieldSelectionViewControl(), DataViewControlsTest\testDataTableHasNoOrderingViewControl(), DataViewControlsTest\testDataTableHasNoOrderingViewControlDueToRecordCount(), DataViewControlsTest\testDataTableHasNoPaginationViewControl(), DataViewControlsTest\testDataTableHasViewControls(), DataViewControlsTest\testDataTableViewControlStorage(), DataTest\testDataTableWithSelectedOptionalCols(), PresentationTest\testFullRendering(), PresentationTest\testMinimalRendering(), PresentationTest\testRenderEmptyTableEntry(), PresentationTest\testRowConstruction(), and PresentationTest\testTableConstruction().

74  : C\Table\Factory
75  {
76  return new C\Table\Factory(
77  new C\SignalGenerator(),
78  $this->getViewControlFactory(),
80  new \ILIAS\Data\Factory(),
81  new C\Table\Column\Factory($this->getLanguage()),
82  new C\Table\Action\Factory(),
83  $this->getMockStorage(),
84  new C\Table\DataRowBuilder(),
85  new C\Table\OrderingRowBuilder()
86  );
87  }
Interface Observer Contains several chained tasks and infos about them.
getLanguage()
Builds data types.
Definition: Factory.php:35
getViewControlContainerFactory()
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getViewControlContainerFactory()

TableTestBase::getViewControlContainerFactory ( )
protected

Definition at line 66 of file TableTestBase.php.

References getViewControlFactory().

Referenced by getTableFactory().

66  : ViewControlContainer\Factory
67  {
68  return new ViewControlContainer\Factory(
69  new C\SignalGenerator(),
70  $this->getViewControlFactory(),
71  );
72  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getViewControlFactory()

TableTestBase::getViewControlFactory ( )
protected

Definition at line 55 of file TableTestBase.php.

References buildFieldFactory(), buildRefinery(), and getLanguage().

Referenced by getTableFactory(), and getViewControlContainerFactory().

55  : ViewControl\Factory
56  {
57  return new ViewControl\Factory(
58  $this->buildFieldFactory(),
59  new \ILIAS\Data\Factory(),
60  $this->buildRefinery(),
61  new C\SignalGenerator(),
62  $this->getLanguage(),
63  );
64  }
Interface Observer Contains several chained tasks and infos about them.
getLanguage()
Builds data types.
Definition: Factory.php:35
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

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