Skip to content

Commit

Permalink
test(scripting): change expect assertions from .equal to .match
Browse files Browse the repository at this point in the history
Signed-off-by: jhpung <[email protected]>
  • Loading branch information
jhpung committed Oct 29, 2024
1 parent 05160a3 commit 011d33a
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions test/functional/scripting.ts
Original file line number Diff line number Diff line change
Expand Up @@ -250,12 +250,8 @@ describe("scripting", () => {
// @ts-expect-error
const [a, b] = await redis.multi().test("foo").test("bar").exec();

expect(a[0].message).to.equal(
"NOSCRIPT No matching script."
);
expect(b[0].message).to.equal(
"NOSCRIPT No matching script."
);
expect(a[0].message).to.match(/^NOSCRIPT No matching script/);
expect(b[0].message).to.match(/^NOSCRIPT No matching script/);
});
spy.restore();
expect(spy.callCount).to.equal(4);
Expand Down

0 comments on commit 011d33a

Please sign in to comment.