コード例 #1
0
 public void testGetGender() throws Exception {
   assertFalse(a.getGender());
   assertTrue(b.getGender());
 }
コード例 #2
0
  public void testGetSetters() throws Exception {
    a.setGender(true);
    assertTrue(a.getGender());

    a.setLvl(1);
    assertEquals(1, a.getLvl());

    a.setNickname("tyrone");
    assertEquals("tyrone", a.getNickname());

    // a.setPlayerID(12);
    // assertEquals(12,a.getPlayerID());

    // a.setPokeID(12);
    // assertEquals(12,a.getID());

    type.clear();
    type.add(PokeType.ROCK);
    a.setType(type);
    assertEquals(PokeType.ROCK, a.getType().get(0));

    a.setLvl(5);
    assertEquals(5, a.getLvl());

    a.setXp(40);
    assertEquals(40, a.getXp());
  }
コード例 #3
0
 public void testGetXp() throws Exception {
   assertEquals(3, a.getXp());
   assertEquals(4, b.getXp());
 }
コード例 #4
0
 public void testGetLvl() throws Exception {
   assertEquals(10, a.getLvl());
   assertEquals(11, b.getLvl());
 }
コード例 #5
0
 public void testGetNickName() throws Exception {
   assertEquals("a", a.getNickname());
   assertEquals("b", b.getNickname());
 }
コード例 #6
0
 public void testGetPokemonName() throws Exception {
   assertEquals("Mew", a.getPokeName());
   assertEquals("Mewtwo", b.getPokeName());
 }
コード例 #7
0
 public void testGetPlayerID() throws Exception {
   assertEquals(2, a.getPlayerID());
   assertEquals(3, b.getPlayerID());
 }
コード例 #8
0
 public void testGetPokeID() throws Exception {
   assertEquals(PokeID.Mew, a.getID());
   assertEquals(PokeID.Mewtwo, b.getID());
 }
コード例 #9
0
 // TODO - add test methods
 public void testGetType() throws Exception {
   assertEquals(PokeType.NORMAL, a.getType().get(0));
   assertEquals(PokeType.NORMAL, b.getType().get(0));
   assertEquals(PokeType.FIRE, b.getType().get(1));
 }