upgrade to rc5 with breaking changes

This commit is contained in:
2024-10-16 15:36:47 +05:30
parent da100fcfb5
commit 1a8d961240
25 changed files with 4616 additions and 3588 deletions

View File

@ -5,25 +5,23 @@ The `medusa-test-utils` package provides utility functions to create integration
For example:
```ts
import { medusaIntegrationTestRunner } from "medusa-test-utils"
import { medusaIntegrationTestRunner } from "medusa-test-utils";
medusaIntegrationTestRunner({
testSuite: ({ api, getContainer }) => {
describe("Custom endpoints", () => {
describe("GET /store/custom", () => {
it("returns correct message", async () => {
const response = await api.get(
`/store/custom`
)
expect(response.status).toEqual(200)
expect(response.data).toHaveProperty("message")
expect(response.data.message).toEqual("Hello, World!")
})
})
})
}
})
const response = await api.get(`/store/custom`);
expect(response.status).toEqual(200);
expect(response.data).toHaveProperty("message");
expect(response.data.message).toEqual("Hello, World!");
});
});
});
},
});
```
Learn more in [this documentation](https://docs.medusajs.com/v2/debugging-and-testing/testing-tools/integration-tests).
Learn more in [this documentation](https://docs.medusajs.com/v2/debugging-and-testing/testing-tools/integration-tests).