MCPcopy Create free account
hub / github.com/PCGen/pcgen / setUp

Method setUp

code/src/test/pcgen/core/prereq/PreShieldProfTest.java:303–352  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

301 }
302
303 @BeforeEach
304 @Override
305 protected void setUp() throws Exception
306 {
307 super.setUp();
308
309 Equipment heavySteelShield = new Equipment();
310 heavySteelShield.setName("Heavy Steel Shield");
311 heavySteelShield.addToListFor(ListKey.TYPE, Type.getConstant("Shield"));
312 heavySteelShield.addToListFor(ListKey.TYPE, Type.getConstant("Heavy"));
313 Globals.getContext().getReferenceContext().importObject(heavySteelShield);
314
315 Equipment heavyWoodenShield = new Equipment();
316 heavyWoodenShield.setName("Heavy Wooden Shield");
317 heavyWoodenShield.addToListFor(ListKey.TYPE, Type.getConstant("Shield"));
318 heavyWoodenShield.addToListFor(ListKey.TYPE, Type.getConstant("Heavy"));
319 Globals.getContext().getReferenceContext().importObject(heavyWoodenShield);
320
321 Equipment lightWoodenShield = new Equipment();
322 lightWoodenShield.setName("Light Steel Shield");
323 lightWoodenShield.addToListFor(ListKey.TYPE, Type.getConstant("Shield"));
324 lightWoodenShield.addToListFor(ListKey.TYPE, Type.getConstant("Light"));
325 Globals.getContext().getReferenceContext().importObject(lightWoodenShield);
326
327 Equipment fullPlateEq = new Equipment();
328 fullPlateEq.setName("Full Plate");
329 fullPlateEq.addToListFor(ListKey.TYPE, Type.getConstant("Shield"));
330 fullPlateEq.addToListFor(ListKey.TYPE, Type.getConstant("Heavy"));
331 Globals.getContext().getReferenceContext().importObject(fullPlateEq);
332
333 ShieldProf fullPlate = new ShieldProf();
334 fullPlate.setName("Full Plate");
335 fullPlate.addToListFor(ListKey.TYPE, Type.getConstant("Heavy"));
336 Globals.getContext().getReferenceContext().importObject(fullPlate);
337
338 ShieldProf lightWood = new ShieldProf();
339 lightWood.setName("Light Wooden Shield");
340 lightWood.addToListFor(ListKey.TYPE, Type.getConstant("Light"));
341 Globals.getContext().getReferenceContext().importObject(lightWood);
342
343 ShieldProf heavyWood = new ShieldProf();
344 heavyWood.setName("Heavy Wooden Shield");
345 heavyWood.addToListFor(ListKey.TYPE, Type.getConstant("Heavy"));
346 Globals.getContext().getReferenceContext().importObject(heavyWood);
347
348 ShieldProf heavySteel = new ShieldProf();
349 heavySteel.setName("Heavy Steel Shield");
350 heavySteel.addToListFor(ListKey.TYPE, Type.getConstant("Heavy"));
351 Globals.getContext().getReferenceContext().importObject(heavySteel);
352 }
353}

Callers

nothing calls this directly

Calls 7

setNameMethod · 0.95
getConstantMethod · 0.95
getContextMethod · 0.95
importObjectMethod · 0.80
addToListForMethod · 0.65
getReferenceContextMethod · 0.65
setNameMethod · 0.65

Tested by

no test coverage detected