@Test
public void testGenerateNewTicket() throws LoginTicketNotFoundException, ExternalAppNotMappedException
{

	assertNotNull(manager);
	LoginTicket ticket = manager.generateNewTicket("test", "testUser");
	assertNotNull(ticket);
	assertFalse(ticket.isExpired());
	LoginTicket removed = manager.removeTicket(ticket.getIdAsString());
	assertEquals(ticket.getId(), removed.getId());
	assertEquals(ticket.getIdAsString(), removed.getIdAsString());
	assertEquals(ticket.getCreationTime(), removed.getCreationTime());
	assertEquals(ticket.getRequistingApplication(), removed.getRequistingApplication());
	assertEquals(ticket.getRequestingApplicationUsername(), removed.getRequestingApplicationUsername());
	assertEquals(ticket.getValidityDuration(), removed.getValidityDuration());
	assertEquals(0, manager.getSize());
}