コード例 #1
0
 @Test
 public void testSetGetPanels() {
   assertEquals(equipment.getPanels(), panels);
   ArrayList<Panel> newPanels = new ArrayList<Panel>();
   equipment.setPanels(newPanels);
   assertEquals(equipment.getPanels(), newPanels);
 }
コード例 #2
0
 @Before
 public void setUp() throws Exception {
   equipment = new Equipment();
   equipment.setCost(COST);
   equipment.setSize(SIZE);
   inverter = new Inverter();
   equipment.setInverter(inverter);
   panels = new ArrayList<Panel>();
   equipment.setPanels(panels);
   battery = new Battery();
   equipment.setBattery(battery);
   inverters = new ArrayList<Inverter>();
 }