Commit 67021577 authored by Jacob Priddy's avatar Jacob Priddy 👌
Browse files

make comment more descriptive and add a tests for cases that were missed

parent b67776c7
Pipeline #2940 failed with stages
in 1 minute and 11 seconds
......@@ -55,6 +55,8 @@ interface Authorizer
/**
* Protects the admin user from being modified.
* Throws an exception if the currently authenticated user does not have
* the permissions to perform an action on the passed user or group
*
* @param string $userId
* @param string|null $groupId
......
......@@ -188,5 +188,6 @@ class UserDatabaseTest extends DatabaseTestCase
$this->assertEquals($user, $this->users->findByDoorcode(new Doorcode('doorcode')));
$this->assertNull($this->users->findByDoorcode(new Doorcode('what doorcode')));
$this->assertNull($this->users->findByDoorcode(null));
}
}
......@@ -78,4 +78,14 @@ class UseCaseTest extends TestCase
$this->assertEquals($door, $this->response->getDoor());
}
/**
* @test
*/
public function it_does_not_find_non_existent_token(): void
{
$this->handleTest('token');
$this->assertNull($this->response->getDoor());
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment