chore(): Remove default limit from the build query (#9257)
* chore(): Remove default limit from the build query * rm take: null * fix tests * fix tests * fix db usage * fix typo * rm unsused template arg * fixes * fixes * fixes * fixes * fixes * fixes * fixes
This commit is contained in:
+5
-8
@@ -35,10 +35,7 @@ moduleIntegrationTestRunner<ICurrencyModuleService>({
|
||||
|
||||
describe("list", () => {
|
||||
it("list currencies", async () => {
|
||||
const currenciesResult = await service.listCurrencies(
|
||||
{},
|
||||
{ take: null }
|
||||
)
|
||||
const currenciesResult = await service.listCurrencies({}, {})
|
||||
expect(currenciesResult).toEqual(
|
||||
expect.arrayContaining([
|
||||
expect.objectContaining({
|
||||
@@ -58,7 +55,7 @@ moduleIntegrationTestRunner<ICurrencyModuleService>({
|
||||
it("list currencies by code", async () => {
|
||||
const currenciesResult = await service.listCurrencies(
|
||||
{ code: ["usd"] },
|
||||
{ take: null }
|
||||
{}
|
||||
)
|
||||
|
||||
expect(currenciesResult).toEqual([
|
||||
@@ -72,7 +69,7 @@ moduleIntegrationTestRunner<ICurrencyModuleService>({
|
||||
it("list currencies by code regardless of case-sensitivity", async () => {
|
||||
const currenciesResult = await service.listCurrencies(
|
||||
{ code: ["Usd"] },
|
||||
{ take: null }
|
||||
{}
|
||||
)
|
||||
|
||||
expect(currenciesResult).toEqual([
|
||||
@@ -87,7 +84,7 @@ moduleIntegrationTestRunner<ICurrencyModuleService>({
|
||||
describe("listAndCountCurrenciesCurrencies", () => {
|
||||
it("should return currencies and count", async () => {
|
||||
const [currenciesResult, count] =
|
||||
await service.listAndCountCurrencies({}, { take: null })
|
||||
await service.listAndCountCurrencies({}, {})
|
||||
|
||||
expect(count).toEqual(120)
|
||||
expect(currenciesResult).toEqual(
|
||||
@@ -110,7 +107,7 @@ moduleIntegrationTestRunner<ICurrencyModuleService>({
|
||||
{
|
||||
code: ["usd"],
|
||||
},
|
||||
{ take: null }
|
||||
{}
|
||||
)
|
||||
|
||||
expect(count).toEqual(1)
|
||||
|
||||
Reference in New Issue
Block a user