◆ setUp()
ilSystemStyleIconTest::setUp |
( |
| ) |
|
|
protected |
Definition at line 48 of file ilSystemStyleIconTest.php.
49 {
51
52 $this->save_dic =
$DIC;
53
55
57
58 mkdir($this->system_style_config->test_skin_temp_path);
60
62 $this->style = $this->container->getSkin()->getStyle("style1");
63 }
ilSystemStyleConfig wraps all 'constants' to ensure the testability of all classes using those 'const...
static generateFromId($skin_id, ilSystemStyleMessageStack $message_stack=null, ilSystemStyleConfig $system_styles_conf=null)
Generate the container class by parsing the corresponding XML.
static xCopy($src, $dest)
Recursive copy of a folder.
References $DIC, ilSystemStyleSkinContainer\generateFromId(), and ilSystemStyleSkinContainer\xCopy().
◆ tearDown()
ilSystemStyleIconTest::tearDown |
( |
| ) |
|
|
protected |
◆ testChangeColor()
ilSystemStyleIconTest::testChangeColor |
( |
| ) |
|
Definition at line 100 of file ilSystemStyleIconTest.php.
101 {
104
105 $icon->changeColors(['505050' => '555555']);
106
112 $expected_color_set->addColor($color1);
113 $expected_color_set->addColor($color2);
114 $expected_color_set->addColor($color3);
115 $expected_color_set->addColor($color4);
116
117 $this->assertEquals($expected_color_set, $icon->getColorSet());
118 }
Abstracts an Icon and the necessary actions to get all colors out of an svg Icon.
References $icon_name, and $path.
◆ testChangeColorInIconFile()
ilSystemStyleIconTest::testChangeColorInIconFile |
( |
| ) |
|
Definition at line 120 of file ilSystemStyleIconTest.php.
121 {
124
125 $icon->changeColors(['505050' => '555555']);
126
132 $expected_color_set->addColor($color1);
133 $expected_color_set->addColor($color2);
134 $expected_color_set->addColor($color3);
135 $expected_color_set->addColor($color4);
136
138
139 $this->assertEquals($expected_color_set, $icon_new->getColorSet());
140 }
References $icon_name, and $path.
◆ testConstruct()
ilSystemStyleIconTest::testConstruct |
( |
| ) |
|
Definition at line 72 of file ilSystemStyleIconTest.php.
73 {
76
77 $this->assertEquals($icon->getName(), $this->icon_name);
78 $this->assertEquals($icon->getPath(),
$path);
79 $this->assertEquals($icon->getType(), $this->icon_type);
80 }
References $icon_name, and $path.
◆ testGetColorSet()
ilSystemStyleIconTest::testGetColorSet |
( |
| ) |
|
Definition at line 82 of file ilSystemStyleIconTest.php.
83 {
86
92 $expected_color_set->addColor($color1);
93 $expected_color_set->addColor($color2);
94 $expected_color_set->addColor($color3);
95 $expected_color_set->addColor($color4);
96
97 $this->assertEquals($expected_color_set, $icon->getColorSet());
98 }
References $icon_name, and $path.
◆ $container
ilSystemStyleIconTest::$container |
|
protected |
◆ $icon_name
ilSystemStyleIconTest::$icon_name = "test_image_1.svg" |
|
protected |
◆ $icon_type
ilSystemStyleIconTest::$icon_type = "svg" |
|
protected |
◆ $save_dic
ilSystemStyleIconTest::$save_dic = null |
|
protected |
◆ $style
ilSystemStyleIconTest::$style |
|
protected |
◆ $system_style_config
ilSystemStyleIconTest::$system_style_config |
|
protected |
The documentation for this class was generated from the following file: