@Test
public void testQueryDetailByPk(){

	//Product查询
	ShopProduct product = new ShopProduct();
	product.setProductName("productName");
	product.setProductType(Constant.SHOP_PRODUCT_TYPE.PRODUCT.name());
	Long pId = shopProductDAO.insert(product);
	ShopProduct p = shopProductDAO.queryDetailByPk(pId);
	
	Assert.assertEquals("productName", p.getProductName());
	Assert.assertEquals(Constant.SHOP_PRODUCT_TYPE.PRODUCT.name(),p.getProductType());
	
	//CouponProduct查询
	ShopProductCoupon c = new ShopProductCoupon();
	c.setProductName("couponProduct");
	c.setProductType(Constant.SHOP_PRODUCT_TYPE.COUPON.name());
	Long cId = shopProductDAO.insert(c);
	ShopProduct cP = shopProductDAO.queryDetailByPk(cId);
	
	Assert.assertEquals("couponProduct", cP.getProductName());
	Assert.assertEquals(Constant.SHOP_PRODUCT_TYPE.COUPON.name(), cP.getProductType());
}