Example #1
0
 @Before
 public void setUp() {
   user = new User();
   user.setEmail("*****@*****.**");
   user.setName("testName");
   user.setPassword("1111");
 }
Example #2
0
  @Test
  public void selectOneTest() {
    // given
    usersDAO.insertOne(user);
    int sequence = user.getSequence();

    // when
    User result = usersDAO.selectOne(sequence);

    // then
    assertThat(result.getSequence(), is(sequence));
    assertThat(result.getEmail(), is(user.getEmail()));
    assertThat(result.getName(), is(user.getName()));
    assertThat(result.getPassword(), is(user.getPassword()));
  }