**What**
> [!NOTE]
> I can see this pr becoming huge, so I d like to get this partial one merged 👍
- Fixes shared connection usage (mikro orm compare the instance to its own package and therefore was resulting in not trully reusing the provided connection leading to exhausting the connection pool as multiple connections was created and end up not being all destroyed properly under the hood, discovered in my integration tests)
- Create shipping options method implementation
- DTO's definition and service interface update
- integration tests
- Re work of the indexes with new util update
- Test runner utils to remove a big chunk of the boilerplate of the packages integrations
FIXES CORE-1742
19 lines
484 B
TypeScript
19 lines
484 B
TypeScript
import {TestDatabaseUtils} from "medusa-test-utils"
|
|
|
|
import * as RegionModels from "@models"
|
|
|
|
const pathToMigrations = "../../src/migrations"
|
|
const mikroOrmEntities = RegionModels as unknown as any[]
|
|
|
|
export const MikroOrmWrapper = TestDatabaseUtils.getMikroOrmWrapper({
|
|
mikroOrmEntities,
|
|
pathToMigrations,
|
|
})
|
|
|
|
export const MikroOrmConfig = TestDatabaseUtils.getMikroOrmConfig({
|
|
mikroOrmEntities,
|
|
pathToMigrations,
|
|
})
|
|
|
|
export const DB_URL = TestDatabaseUtils.getDatabaseURL()
|