Esempio n. 1
0
 public function testAuthenticateWithNotExistingUser()
 {
     $this->markTestNeedsDatabase();
     $instance = new Erfurt_Auth_Adapter_Rdf('UserDoesNotExist', 'wrongPass');
     $result = $instance->authenticate();
     $this->assertFalse($result->isValid());
 }
Esempio n. 2
0
 public function testAuthenticateAnonymous()
 {
     $instance = new Erfurt_Auth_Adapter_Rdf('Anonymous');
     $result = $instance->authenticate();
     $id = $result->getIdentity();
     $this->assertTrue($result->isValid());
     $this->assertEquals('Anonymous', $id->getUsername());
     $this->assertTrue($id->isAnonymousUser());
 }