Skip to content

Commit

Permalink
Update test code
Browse files Browse the repository at this point in the history
  • Loading branch information
seratch committed Apr 25, 2024
1 parent 07dcd88 commit 331f1a1
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions test/retry-handler.test.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,4 @@
import {
assert,
test,
describe,
expect,
afterAll,
afterEach,
beforeAll,
} from "vitest";
import { test, describe, expect, afterAll, afterEach, beforeAll } from "vitest";
import {
ServerErrorRetryHandler,
SlackAPIClient,
Expand Down Expand Up @@ -38,7 +30,7 @@ describe("Retry handlers", () => {
);
const client = new SlackAPIClient(undefined, { logLevel: "DEBUG" });
const response = await client.auth.test();
assert.equal(response.error, undefined);
expect(response.ok).true;
});
test("exceeding max attempts", async () => {
const responses = [
Expand Down Expand Up @@ -94,7 +86,7 @@ describe("Retry handlers", () => {
const client = new SlackAPIClient(undefined, { logLevel: "DEBUG" });
client.retryHanlders.push(new ServerErrorRetryHandler());
const response = await client.auth.test();
assert.equal(response.error, undefined);
expect(response.ok).true;
});
});
});

0 comments on commit 331f1a1

Please sign in to comment.