Skip to content

Commit

Permalink
chore: test coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
UnderKoen committed May 22, 2024
1 parent a5b4b6a commit 4a46729
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 1 deletion.
2 changes: 1 addition & 1 deletion test/CsvOrder.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ describe("getOrders", function () {
// arrange

// act
while (await order.getOrders({}).then((x) => x.data.length < 1)) {
while (await order.getOrders().then((x) => x.data.length < 1)) {
await order.refresh();
await sleep(1000);
}
Expand Down
22 changes: 22 additions & 0 deletions test/PrintOne.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1908,6 +1908,28 @@ describe("getBatches", function () {
);
});

it("should use the status filter (single)", async function () {
// arrange

// act
const batches = await client.getBatches({
limit: 1,
filter: {
status: BatchStatus.batch_sent,
},
});
const batch = batches.data[0];

if (batch === undefined) {
console.warn("No batches found, skipping test");
return;
}

// assert
expect(batch).toBeDefined();
expect(batch.status).toEqual(expect.toBeOneOf([BatchStatus.batch_created]));
});

it("should use the status filter (single)", async function () {
// arrange

Expand Down

0 comments on commit 4a46729

Please sign in to comment.