Browse Source

updated Aauth/ErrorsTest.php

v3-dev
REJack 6 years ago
parent
commit
aa82241e44
No known key found for this signature in database
GPG Key ID: 4A44B48700429F46
  1. 13
      tests/Aauth/Libraries/Aauth/ErrorsTest.php

13
tests/Aauth/Libraries/Aauth/ErrorsTest.php

@ -55,8 +55,15 @@ class ErrorsTest extends \CIUnitTestCase
public function testErrors()
{
$session = $this->getInstance();
$this->library = new Aauth(NULL, $session);
$this->library = new Aauth(NULL, TRUE);
$this->assertCount(0, $this->library->getErrorsArray());
$this->library->error('test message 1');
$this->assertCount(1, $this->library->getErrorsArray());
}
public function testgetErrorsArray()
{
$this->library = new Aauth(NULL, TRUE);
$this->assertCount(0, $this->library->getErrorsArray());
$this->library->error('test message 1');
$this->assertCount(1, $this->library->getErrorsArray());
@ -66,7 +73,7 @@ class ErrorsTest extends \CIUnitTestCase
{
$session = $this->getInstance();
$this->library = new Aauth(NULL, $session);
$this->assertFalse($session->get('errors'));
$this->assertNull($session->get('errors'));
$this->library->error('test message 1', true);
$this->assertCount(1, $session->get('errors'));
}

Loading…
Cancel
Save