Skip to content

Commit f89adcc

Browse files
committed
CartMutationsTest updated
1 parent 27d74e2 commit f89adcc

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

tests/wpunit/CartMutationsTest.php

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -716,12 +716,17 @@ public function testApplyCouponMutation() {
716716
$cart = WC()->cart;
717717

718718
// Create products.
719-
$product_id = $this->product->create_simple();
719+
$product_id = $this->product->create_simple(
720+
array( 'regular_price' => 100 )
721+
);
720722

721723
// Create coupon.
722724
$coupon_code = wc_get_coupon_code_by_id(
723725
$this->coupon->create(
724-
array( 'product_ids' => array( $product_id ) )
726+
array(
727+
'amount' => 0.5,
728+
'product_ids' => array( $product_id )
729+
)
725730
)
726731
);
727732

0 commit comments

Comments
 (0)