$this->
assertLineItemTotalPrice($cart,
$product->id, 100
);
$orderId =
$this->
mailListener(function DMailEventListener
$listener) use ($cart,
$context) { $orderId =
$this->
order($cart,
$context);
$listener->
assertSent('order_confirmation_mail'
);
return $orderId;
});
$item =
$this->
assertProductInOrder($orderId,
$product->id
);
static::
assertEquals(100,
$item->
getUnitPrice());
static::
assertEquals(100,
$item->
getTotalPrice());
if (Feature::
isActive('STOCK_HANDLING'
)) { $this->
assertStock($product->id, 99, 99
);
} else { $this->
assertStock($product->id, 100, 99
);
} }}