Added additional test case for ItemEntry super class

This commit is contained in:
Collin Smith 2020-12-31 13:53:37 -08:00
parent 72a83fa81e
commit e0d4884b96

View File

@ -65,6 +65,20 @@ public class TablesTest extends RiiabloTest {
Assert.assertEquals("ReturnedArcher", record.NameStr);
}
@Test
public void weapons_superclass_access() {
FileHandle handle = Gdx.files.internal("test/weapons.txt");
TsvParser parser = TsvParser.parse(handle.readBytes());
TableManifest.weapons.parser = null;
WeaponsTable table = Tables.loadTsv(TableManifest.weapons, parser);
Weapons record;
record = table.get(54);
Assert.assertEquals("Brandistock", record.name);
Assert.assertEquals("spea", record.type);
Assert.assertEquals("BRN", record.code);
Assert.assertEquals("2ht", record.wclass);
}
@Test
public void weapons_random_access() {
FileHandle handle = Gdx.files.internal("test/weapons.txt");