fix(medusa-payment-klarna): Fix division by zero on free shipping (#1840)

This commit is contained in:
Sebastian Rindom
2022-07-13 09:26:45 +02:00
committed by GitHub
parent 4e375c2203
commit c20d720040
4 changed files with 29 additions and 17 deletions
@@ -75,7 +75,7 @@ Object {
"ends_at": "2022-12-31T00:00:00.000Z",
"id": "pl_no_customer_groups",
"name": "Loyalty Reward - Winter Sale",
"prices": Array [
"prices": ArrayContaining [
Object {
"amount": 100,
"created_at": Any<String>,
@@ -471,7 +471,7 @@ describe("/admin/price-lists", () => {
status: "draft",
starts_at: "2022-09-01T00:00:00.000Z",
ends_at: "2022-12-31T00:00:00.000Z",
prices: [
prices: expect.arrayContaining([
{
id: expect.any(String),
amount: 100,
@@ -483,6 +483,7 @@ describe("/admin/price-lists", () => {
region_id: null,
created_at: expect.any(String),
updated_at: expect.any(String),
deleted_at: null,
},
{
id: expect.any(String),
@@ -495,6 +496,7 @@ describe("/admin/price-lists", () => {
region_id: null,
created_at: expect.any(String),
updated_at: expect.any(String),
deleted_at: null,
},
{
id: expect.any(String),
@@ -507,6 +509,7 @@ describe("/admin/price-lists", () => {
region_id: null,
created_at: expect.any(String),
updated_at: expect.any(String),
deleted_at: null,
},
{
id: expect.any(String),
@@ -534,7 +537,7 @@ describe("/admin/price-lists", () => {
updated_at: expect.any(String),
deleted_at: null,
},
],
]),
customer_groups: [
{
id: "customer-group-1",