单元测试修正

This commit is contained in:
thinkphp
2016-06-06 14:29:11 +08:00
parent 0efb5d02fd
commit 936b1e20e9
2 changed files with 4 additions and 4 deletions

View File

@@ -23,12 +23,12 @@ class logTest extends \PHPUnit_Framework_TestCase
public function testRecord(){
Log::clear();
Log::record('test');
$this->assertEquals([['type'=>'log','msg'=>'test']], Log::getLog());
$this->assertEquals(['log'=>['test'], Log::getLog());
Log::record('hello','info');
$this->assertEquals([['type'=>'log','msg'=>'test'],['type'=>'info','msg'=>'hello']], Log::getLog());
$this->assertEquals(['log'=>['test'],'info'=>['hello']], Log::getLog());
Log::clear();
Log::info('test');
$this->assertEquals([['type'=>'info','msg'=>'test']], Log::getLog());
$this->assertEquals(['info'=>['test']], Log::getLog());
}
public function testSave(){