From a789ad8966235116445ce41eb68b57255f39e948 Mon Sep 17 00:00:00 2001 From: Anton Terekhov Date: Wed, 21 Nov 2012 14:31:43 +0400 Subject: [PATCH] More strict test on autoload --- tests/LoadTest.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/LoadTest.php b/tests/LoadTest.php index 34f3097..a70e8cb 100644 --- a/tests/LoadTest.php +++ b/tests/LoadTest.php @@ -150,12 +150,11 @@ class LoadTest extends PHPUnit_Framework_TestCase $this->setConstants(); Load::setAutoloadFrom(self::$file); $autoload = require(self::$file); - $this->setExpectedException('PHPUnit_Framework_Error'); - $this->assertNotEmpty(Load::getFilePath('anton')); + $this->setExpectedException('PHPUnit_Framework_Error', 'Undefined index'); + $this->assertNotEmpty(Load::getFilePath('ClassDontExist')); } /** - * @TODO: Load::autoload() needs self::$autoload = require(self::$file); after self::buildAutoload(); * @runInSeparateProcess */ public function testDebugAutoload()