ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
FieldFactoryTest Class Reference
+ Inheritance diagram for FieldFactoryTest:
+ Collaboration diagram for FieldFactoryTest:

Public Member Functions

 buildFactory ()
 
 test_implements_factory_interface ()
 
- Public Member Functions inherited from AbstractFactoryTest
 buildFactoryReflection ()
 
 methods_provider ()
 
 setUp ()
 
 test_proper_namespace ()
 
 test_proper_name ()
 
 test_check_yaml_extraction ($method_reflection, $name)
 Tests whether the YAML Kitchen Sink info can be parsed. More...
 
 test_return_type ($method_reflection, $name)
 Tests whether the method either returns a factory or a component. More...
 
 test_factory_method_name_compatible_docstring ($method_reflection, $name)
 Tests whether the method name matches the. More...
 
 test_method_params ($method_reflection, $name)
 Tests whether methods returning factories have no parameters. More...
 
 test_kitchensink_info_description ($method_reflection, $name)
 methods_provider More...
 
 test_kitchensink_info_rivals ($method_reflection, $name)
 methods_provider More...
 
 test_kitchensink_info_background ($method_reflection, $name)
 methods_provider More...
 
 test_kitchensink_info_featurewiki ($method_reflection, $name)
 methods_provider More...
 
 test_kitchensink_info_javascript ($method_reflection, $name)
 methods_provider More...
 
 test_kitchensink_info_rules ($method_reflection, $name)
 methods_provider More...
 
 test_kitchensink_info_context ($method_reflection, $name)
 methods_provider More...
 
 kitchensink_info_settings_merged_with_defaults ($name)
 

Data Fields

 $kitchensink_info_settings
 
 $factory_title = 'ILIAS\\UI\\Component\\Input\\Field\\Factory'
 
- Data Fields inherited from AbstractFactoryTest
const COMPONENT = 1
 
const FACTORY = 2
 

Additional Inherited Members

- Protected Member Functions inherited from AbstractFactoryTest
 returnsFactory ($docstring_data)
 
 returnsComponent ($docstring_data)
 
 isFactoryName ($name)
 
 get_regex_factory_namespace ()
 

Detailed Description

Definition at line 11 of file FieldFactoryTest.php.

Member Function Documentation

◆ buildFactory()

FieldFactoryTest::buildFactory ( )
final

Definition at line 48 of file FieldFactoryTest.php.

Referenced by test_implements_factory_interface().

49  {
50  $df = new Data\Factory();
51  return new \ILIAS\UI\Implementation\Component\Input\Field\Factory(
52  new SignalGenerator(),
53  $df,
54  new Validation\Factory($df, $this->createMock(\ilLanguage::class)),
56  );
57  }
A transformation is a function from one datatype to another.
Builds data types.
Definition: Factory.php:14
+ Here is the caller graph for this function:

◆ test_implements_factory_interface()

FieldFactoryTest::test_implements_factory_interface ( )

Definition at line 60 of file FieldFactoryTest.php.

References $f, $text, and buildFactory().

61  {
62  $f = $this->buildFactory();
63 
64  $text = $f->text("label", "byline");
65  $this->assertInstanceOf(Field\Input::class, $text);
66  $this->assertInstanceOf(Field\Text::class, $text);
67 
68  $text = $f->numeric("label", "byline");
69  $this->assertInstanceOf(Field\Input::class, $text);
70  $this->assertInstanceOf(Field\Numeric::class, $text);
71 
72  $text = $f->section([], "label", "byline");
73  $this->assertInstanceOf(Field\Input::class, $text);
74  $this->assertInstanceOf(Field\Group::class, $text);
75  $this->assertInstanceOf(Field\Section::class, $text);
76 
77  $text = $f->group([]);
78  $this->assertInstanceOf(Field\Input::class, $text);
79  $this->assertInstanceOf(Field\Group::class, $text);
80  }
$text
Definition: errorreport.php:18
+ Here is the call graph for this function:

Field Documentation

◆ $factory_title

FieldFactoryTest::$factory_title = 'ILIAS\\UI\\Component\\Input\\Field\\Factory'

Definition at line 45 of file FieldFactoryTest.php.

◆ $kitchensink_info_settings

FieldFactoryTest::$kitchensink_info_settings

Definition at line 13 of file FieldFactoryTest.php.


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