diff --git a/tests/Aauth/Libraries/Aauth/ErrorsTest.php b/tests/Aauth/Libraries/Aauth/ErrorsTest.php
index f7b628a..63cd029 100644
--- a/tests/Aauth/Libraries/Aauth/ErrorsTest.php
+++ b/tests/Aauth/Libraries/Aauth/ErrorsTest.php
@@ -69,7 +69,7 @@ class ErrorsTest extends \CIUnitTestCase
$this->assertEquals(['test message 1','test message 2'], $this->library->getErrorsArray());
}
- public function testPrintErrors()
+ public function testPrintErrorsReturn()
{
$this->library = new Aauth(NULL, TRUE);
$this->library->error('test message 1');
@@ -78,6 +78,14 @@ class ErrorsTest extends \CIUnitTestCase
$this->assertEquals('test message 1
test message 2', $this->library->printErrors('
', true));
}
+ public function testPrintErrorsEcho()
+ {
+ $this->library = new Aauth(NULL, TRUE);
+ $this->library->error('test message 1');
+ $this->library->printErrors('
');
+ $this->expectOutputString('test message 1');
+ }
+
public function testClearErrors()
{
$session = $this->getInstance();
@@ -88,18 +96,6 @@ class ErrorsTest extends \CIUnitTestCase
$this->assertNull($session->get('errors'));
}
- public function testKeepErrorsInclude()
- {
- $session = $this->getInstance();
- $this->library = new Aauth(NULL, $session);
- $this->library->error('test message 1 nonFlash');
- $this->assertNull($session->get('errors'));
- $this->library->error('test message 1 Flash', true);
- $this->assertEquals(['test message 1 Flash'], $session->get('errors'));
- $this->library->keepErrors(true);
- $this->assertEquals(['test message 1 Flash', 'test message 1 nonFlash'], $session->get('errors'));
- }
-
public function testErrorsFlash()
{
$session = $this->getInstance();