@Test public void testFindByProperty() throws Exception { Address address = new Address(); address.setCity("xian"); List<RentGoods> rentGoodsList = rentGoodsDao.findByProperty("address.city", "xian", 1, -1); System.out.println(rentGoodsList); }
@Test public void testFindByAddress() throws Exception { Address address = new Address(); address.setCity("xian"); address.setCountry("changan"); address.setProvince("shanxi"); address.setDistrict("xianyoudian"); List<RentGoods> list = rentGoodsDao.findByAddress(address, 1, -1); System.out.println(list); }
@Test public void testGetRentGoodsBySearch() throws Exception { System.out.println(rentGoodsDao.getRentGoodsBySearch("房", 1, 4)); }
@Test public void testGetRentGoodsByPage() throws Exception { System.out.println(rentGoodsDao.getRentGoodsByPage(1, 5)); }
@Test public void testDelete() throws Exception { rentGoodsDao.delete(RentGoods.class, 2); }
@Test public void testFindByOrder() throws Exception { System.out.println(rentGoodsDao.findByOrder(4, 1, 5)); }
@Test public void testAddPath() throws Exception { // RentGoods rentGoods = rentGoodsDao.get(RentGoods.class, 2); rentGoodsDao.addPath(2, "/picture"); }
@Test public void testFingByClassify() throws Exception { List<RentGoods> list = rentGoodsDao.findByClassify("gzi", 1, 3); System.out.println(list); }
@Test public void testGetOrderUser() throws Exception { User user = rentGoodsDao.getOrderUser(2); System.out.println(user.getId()); }