fix: allow backorder variants to be added to cart even if no locations (#12083)

* fix: allow backorder variants to be added to cart even if no locations

* document and unit test prepareConfirmInventoryInput
This commit is contained in:
Pedro Guzman
2025-04-09 19:15:42 +02:00
committed by GitHub
parent f615ebb7e8
commit 8804ca2f9c
6 changed files with 634 additions and 17 deletions

View File

@@ -80,7 +80,7 @@ async function populateData(api: any) {
console.log(err)
})
await setTimeout(2000)
await setTimeout(10000)
}
process.env.ENABLE_INDEX_MODULE = "true"

View File

@@ -153,7 +153,7 @@ medusaIntegrationTestRunner({
})
// Timeout to allow indexing to finish
await setTimeout(4000)
await setTimeout(10000)
const { data: results } = await fetchAndRetry(
async () =>

View File

@@ -17,7 +17,7 @@ import {
} from "../../../helpers/create-admin-user"
import { setupTaxStructure } from "../fixtures"
jest.setTimeout(50000)
jest.setTimeout(100000)
const env = { MEDUSA_FF_MEDUSA_V2: true }
@@ -165,6 +165,14 @@ medusaIntegrationTestRunner({
inventory_item_id: inventoryItem.id,
},
},
{
[Modules.PRODUCT]: {
variant_id: product_2.variants[0].id,
},
[Modules.INVENTORY]: {
inventory_item_id: inventoryItem.id,
},
},
])
await setupTaxStructure(taxModule)