mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-18 02:26:17 +00:00
Separated the tests for HtmlHelper::loadConfig() with exception in different methods.
This commit is contained in:
parent
dc4357f636
commit
95713fbf3b
1 changed files with 17 additions and 4 deletions
|
@ -1399,14 +1399,27 @@ class HtmlHelperTest extends CakeTestCase {
|
|||
);
|
||||
$this->assertEqual($result, $expected);
|
||||
$this->assertEqual($this->Html->getAttribute('_minimizedAttributeFormat'), 'format');
|
||||
}
|
||||
|
||||
$this->expectException('ConfigureException');
|
||||
/**
|
||||
* testLoadConfigWrongFile method
|
||||
*
|
||||
* @return void
|
||||
* @expectedException ConfigureException
|
||||
*/
|
||||
public function testLoadConfigWrongFile() {
|
||||
$result = $this->Html->loadConfig('wrong_file');
|
||||
$this->assertFalse($result);
|
||||
}
|
||||
|
||||
$this->expectException('ConfigureException');
|
||||
/**
|
||||
* testLoadConfigWrongReader method
|
||||
*
|
||||
* @return void
|
||||
* @expectedException ConfigureException
|
||||
*/
|
||||
public function testLoadConfigWrongReader() {
|
||||
$path = TEST_CAKE_CORE_INCLUDE_PATH . 'tests' . DS . 'test_app' . DS . 'config'. DS;
|
||||
$result = $this->Html->loadConfig(array('htmlhelper_tags', 'wrong_reader'), $path);
|
||||
$this->assertFalse($result);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Reference in a new issue