feat(core-flows,framework,medusa): list shipping options pass in cart as pricing context (#10374)

* feat(core-flows,framework,medusa): list shipping options pass in cart as pricing context

* chore: add test for shipping options returning free shipping
This commit is contained in:
Riqwan Thamir authored and GitHub committed 2024-12-01 20:59:26 +01:00
1 parent eacd691951
commit 11bd556133
12 files changed
+284 -156

No files matched your search

@@ -152,12 +152,12 @@ medusaIntegrationTestRunner({
amount: 500,
rules: [
{
attribute: "cart_total",
attribute: "total",
operator: "gte",
value: 100,
},
{
attribute: "cart_total",
attribute: "total",
operator: "lte",
value: 200,
},
@@ -218,12 +218,12 @@ medusaIntegrationTestRunner({
rules_count: 2,
price_rules: expect.arrayContaining([
expect.objectContaining({
attribute: "cart_total",
attribute: "total",
operator: "gte",
value: "100",
}),
expect.objectContaining({
attribute: "cart_total",
attribute: "total",
operator: "lte",
value: "200",
}),
@@ -327,7 +327,7 @@ medusaIntegrationTestRunner({
amount: 500,
rules: [
{
attribute: "cart_total",
attribute: "total",
operator: "gt",
value: 200,
},
@@ -378,7 +378,7 @@ medusaIntegrationTestRunner({
rules_count: 2,
price_rules: expect.arrayContaining([
expect.objectContaining({
attribute: "cart_total",
attribute: "total",
operator: "gt",
value: "200",
}),
@@ -458,7 +458,7 @@ medusaIntegrationTestRunner({
amount: 500,
rules: [
{
attribute: "cart_total",
attribute: "total",
operator: "not_whitelisted",
value: 100,
},
@@ -496,7 +496,7 @@ medusaIntegrationTestRunner({
amount: 500,
rules: [
{
attribute: "cart_total",
attribute: "total",
operator: "gt",
value: "string",
},
@@ -626,7 +626,7 @@ medusaIntegrationTestRunner({
amount: 5,
rules: [
{
attribute: "cart_total",
attribute: "total",
operator: "gt",
value: 200,
},
@@ -702,7 +702,7 @@ medusaIntegrationTestRunner({
amount: 5,
price_rules: [
expect.objectContaining({
attribute: "cart_total",
attribute: "total",
operator: "gt",
value: "200",
}),