import junit.framework.TestCase;
public class TestUser extends TestCase{
public void testUser() throws Exception {
IUser user = new User();
user.setEmail("blah@mail.com");
user.setStructureId(2);
user.setName("dharmesh");
user.setPassword("password");
user.setPasswordConfirm("password");
Role role = new Role();
role.setDescription("guest");
role.setName("guest");
user.setRole(role);
user.setUserName("dappers");
user.setSurname("dillip");
user.setLanguage("it");
assertEquals("blah@mail.com",user.getEmail());
assertEquals(2,user.getStructureId());
assertEquals("dharmesh", user.getName());
assertEquals("password", user.getPassword());
assertEquals("password", user.getPasswordConfirm());
assertEquals(role, user.getRole());
assertEquals("dillip", user.getSurname());
assertEquals("it",user.getLanguage());
assertTrue(user.isGuest());
}