File tree Expand file tree Collapse file tree 1 file changed +26
-0
lines changed
dev/tests/unit/testsuite/Magento/Framework/HTTP/PhpEnvironment Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -173,4 +173,30 @@ public function testGetFiles()
173
173
$ this ->assertNull ($ this ->model ->getFiles ('no_such_file ' ));
174
174
$ this ->assertEquals ('default ' , $ this ->model ->getFiles ('no_such_file ' , 'default ' ));
175
175
}
176
+
177
+ public function testGetBaseUrlWithUrl ()
178
+ {
179
+ $ this ->model = $ this ->getModel ();
180
+ $ this ->model ->setBaseUrl ('http://test.com/one/two ' );
181
+ $ this ->assertEquals ('http://test.com/one/two ' , $ this ->model ->getBaseUrl ());
182
+ }
183
+
184
+ public function testGetBaseUrlWithEmptyUrl ()
185
+ {
186
+ $ this ->model = $ this ->getModel ();
187
+ $ this ->assertEmpty ($ this ->model ->getBaseUrl ());
188
+ }
189
+
190
+ public function testGetAliasWhenAliasSet ()
191
+ {
192
+ $ this ->model = $ this ->getModel ();
193
+ $ this ->model ->setAlias ('AliasName ' , 'AliasTarget ' );
194
+ $ this ->assertEquals ('AliasTarget ' , $ this ->model ->getAlias ('AliasName ' ));
195
+ }
196
+
197
+ public function testGetAliasWhenAliasAreEmpty ()
198
+ {
199
+ $ this ->model = $ this ->getModel ();
200
+ $ this ->assertNull ($ this ->model ->getAlias ('' ));
201
+ }
176
202
}
You can’t perform that action at this time.
0 commit comments