summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/codeigniter/core/Loader_test.php16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/codeigniter/core/Loader_test.php b/tests/codeigniter/core/Loader_test.php
index 93ca5b223..9e2092e05 100644
--- a/tests/codeigniter/core/Loader_test.php
+++ b/tests/codeigniter/core/Loader_test.php
@@ -405,12 +405,19 @@ class Loader_test extends CI_TestCase {
// Create model in VFS package path
$dir = 'third-party';
$lib = 'unit_test_package';
- $class = 'CI_'.ucfirst($lib);
+ $class = ucfirst($lib);
$this->ci_vfs_create(ucfirst($lib), '<?php class '.$class.' { }', $this->ci_app_root, array($dir, 'libraries'));
// Get paths
$paths = $this->load->get_package_paths(TRUE);
+ // Test failed load without path
+ $this->setExpectedException(
+ 'RuntimeException',
+ 'CI Error: Unable to load the requested class: '.ucfirst($lib)
+ );
+ $this->load->library($lib);
+
// Add path and verify
$path = APPPATH.$dir.'/';
$this->assertInstanceOf('CI_Loader', $this->load->add_package_path($path));
@@ -432,13 +439,6 @@ class Loader_test extends CI_TestCase {
// Remove path and verify restored paths
$this->assertInstanceOf('CI_Loader', $this->load->remove_package_path($path));
$this->assertEquals($paths, $this->load->get_package_paths(TRUE));
-
- // Test failed load without path
- $this->setExpectedException(
- 'RuntimeException',
- 'CI Error: Unable to load the requested class: '.ucfirst($lib)
- );
- $this->load->library($lib);
}
// --------------------------------------------------------------------