public void testValidateAssassinWithGun() {
    EntityManager em = createEntityManager();

    Assassin assassin = em.find(Assassin.class, assassinId);
    assertNotNull("The assassin could not be read back.", assassin);

    Weapon weapon = assassin.getWeapon();
    assertNotNull("The assassin's weapon was null", weapon);
    assertTrue("The assassin's weapon was not a direct weapon", weapon.isDirectWeapon());
    assertTrue("The assassin's weapon was not a gun", ((DirectWeapon) weapon).isGun());

    closeEntityManager(em);
  }
  public void testValidateAssassinWithBombAndEliminations() {
    EntityManager em = createEntityManager();

    Assassin assassin = em.find(Assassin.class, assassinId);
    assertNotNull("The assassin could not be read back.", assassin);
    assassin.getEliminations();
    assertFalse("The assassin didn't have any eliminations", assassin.getEliminations().isEmpty());

    Weapon weapon = assassin.getWeapon();
    assertNotNull("The assassin's weapon was null", weapon);
    assertTrue("The assassin's weapon was not an indirect weapon", weapon.isIndirectWeapon());
    assertTrue("The assassin's weapon was not a bomb", ((IndirectWeapon) weapon).isBomb());

    closeEntityManager(em);
  }