fix(medusa): improve list shipping option (#2383)
This commit is contained in:
+2
-3
@@ -19,11 +19,10 @@ describe("GET /store/shipping-options", () => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
it("calls CartService retrieve", () => {
|
it("calls CartService retrieve", () => {
|
||||||
expect(CartServiceMock.retrieve).toHaveBeenCalledTimes(1)
|
expect(CartServiceMock.retrieveWithTotals).toHaveBeenCalledTimes(1)
|
||||||
expect(CartServiceMock.retrieve).toHaveBeenCalledWith(
|
expect(CartServiceMock.retrieveWithTotals).toHaveBeenCalledWith(
|
||||||
IdMap.getId("emptyCart"),
|
IdMap.getId("emptyCart"),
|
||||||
{
|
{
|
||||||
select: ["subtotal"],
|
|
||||||
relations: [
|
relations: [
|
||||||
"region",
|
"region",
|
||||||
"items",
|
"items",
|
||||||
|
|||||||
@@ -55,8 +55,7 @@ export default async (req, res) => {
|
|||||||
"shippingProfileService"
|
"shippingProfileService"
|
||||||
)
|
)
|
||||||
|
|
||||||
const cart = await cartService.retrieve(cart_id, {
|
const cart = await cartService.retrieveWithTotals(cart_id, {
|
||||||
select: ["subtotal"],
|
|
||||||
relations: [
|
relations: [
|
||||||
"region",
|
"region",
|
||||||
"items",
|
"items",
|
||||||
|
|||||||
Reference in New Issue
Block a user