@Test(expected = UnsupportedOperationException.class)
public void registerTwiceDifferentTypes() {

    registry.register(TestUser.KEY, TestUser.class);
    registry.register(TestUser.KEY, Persistable.class);
}