Ejemplo n.º 1
0
 @Test
 public void testCheckInventoryMulti() {
   ShoppingCartItem scItem =
       new ShoppingCartItem("F0003", "Black-eyed Susan", "2 plants", 8.0f, 9.0f, 9, 10);
   Collection<ShoppingCartItem> scItemsColln = new ArrayList<ShoppingCartItem>();
   // System.out.println("Shopping :: "+applicationContext);
   scItemsColln.add(scItem);
   shopping.checkInventory(scItemsColln);
   assertTrue(true);
 }
Ejemplo n.º 2
0
  @Test
  public void testCheckInventory() {

    ShoppingCartItem scItem =
        new ShoppingCartItem("F0003", "Black-eyed Susan", "2 plants", 8.0f, 9.0f, 9, 10);

    // System.out.println("Shopping :: "+applicationContext);
    shopping.checkInventory(scItem);
    assertTrue(true);
  }
Ejemplo n.º 3
0
  @Test
  @Transactional
  public void testCreateOrder() {
    ShoppingCartItem scItem =
        new ShoppingCartItem("F0003", "Black-eyed Susan", "2 plants", 8.0f, 9.0f, 9, 10);
    Collection<ShoppingCartItem> scItemsColln = new ArrayList<ShoppingCartItem>();
    // System.out.println("Shopping :: "+applicationContext);
    scItemsColln.add(scItem);
    try {
      OrderInfo orderInfo =
          shopping.createOrder(
              "*****@*****.**",
              "TESTBILL",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              "ADDDRRR",
              1,
              scItemsColln);
    } catch (Exception e) {
      // TODO: handle exception
    }

    // System.out.println(" Order ID :: "+orderInfo.getID());
    // assertNotNull(orderInfo);
    assertTrue(true);
  }