diff --git a/tests/thinkphp/library/think/viewTest.php b/tests/thinkphp/library/think/viewTest.php index 44b101a4..4c956566 100644 --- a/tests/thinkphp/library/think/viewTest.php +++ b/tests/thinkphp/library/think/viewTest.php @@ -121,13 +121,14 @@ class viewTest extends \PHPUnit_Framework_TestCase public function testParseTemplate() { $view_instance = \think\View::instance(); + $view_instance->theme('theme'); $view_instance->config(['view_path' => __DIR__ . DS . 'view' . DS]); $method = new \ReflectionMethod('\think\View', 'ParseTemplate'); $method->setAccessible(true); if (defined('CONTROLLER_NAME')) { - $expect_data = __DIR__ . DS . 'view' . DS . 'theme_name' . DS . CONTROLLER_NAME . DS . 'template.html'; + $expect_data = __DIR__ . DS . 'view' . DS . 'theme' . DS . CONTROLLER_NAME . DS . 'template.html'; } else { - $expect_data = __DIR__ . DS . 'view' . DS . 'theme_name' . DS . 'template.html'; + $expect_data = __DIR__ . DS . 'view' . DS . 'theme' . DS . 'template.html'; } $this->assertEquals($expect_data, $method->invoke($view_instance, 'template')); }