Skip to content

Commit

Permalink
Code formatting [slip ci]
Browse files Browse the repository at this point in the history
  • Loading branch information
cedx committed Jan 24, 2024
1 parent 25f3318 commit 5a83055
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions test/client_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,11 @@ describe("Client", () => {
});

describe("checkComment()", () => {
it("should return `CheckResult.ham` for valid comment (e.g. ham)", async () => {
equal(await client.checkComment(ham), CheckResult.ham);
});
it("should return `CheckResult.ham` for valid comment (e.g. ham)", async () =>
equal(await client.checkComment(ham), CheckResult.ham));

it("should return `CheckResult.spam` for invalid comment (e.g. spam)", async () => {
const isSpam = /** @type {CheckResult[]} */ ([CheckResult.spam, CheckResult.pervasiveSpam]);
const isSpam = [CheckResult.spam, CheckResult.pervasiveSpam];
ok(isSpam.includes(await client.checkComment(spam)));
});
});
Expand All @@ -60,12 +59,10 @@ describe("Client", () => {
});

describe("verifyKey()", () => {
it("should return `true` for a valid API key", async () => {
ok(await client.verifyKey());
});
it("should return `true` for a valid API key", async () =>
ok(await client.verifyKey()));

it("should return `false` for an invalid API key", async () => {
equal(await new Client("0123456789-ABCDEF", client.blog, {isTest: true}).verifyKey(), false);
});
it("should return `false` for an invalid API key", async () =>
equal(await new Client("0123456789-ABCDEF", client.blog, {isTest: true}).verifyKey(), false));
});
});

0 comments on commit 5a83055

Please sign in to comment.