@Test public void addDealTest() { deal = new Deal(); deal.setCode("600004"); deal.setDate(new Date()); deal.setOpen(199); dealService.addDeal(deal); }
@Before public void initDeal() { deal = new Deal(); deal.setCode("600004"); deal.setCapitalization(4F); deal.setClose(3F); deal.setDate(new Date()); deal.setHigh(5F); deal.setLow(2F); deal.setOpen(1F); deal.setTurnover(0.2F); deal.setVolume(2.2F); criteria = new DealQueryCriteria(); criteria.setCode("600004"); criteria.setStartDate("2015-02-01"); criteria.setEndDate("2015-09-01"); }
@Test public void findByDateIntervalTest() { Deal d = dealService.findByDateInterval(deal.getCode(), new Date(), new Date()).get(0); System.out.println(d); }
@Test public void deleteTest() { Deal d = dealService.findByCode(deal.getCode()).get(0); dealService.delete(d); }
@Test public void findByCodeTest() { Deal d = dealService.findByCode(deal.getCode()).get(0); System.out.println(d); }