diff options
Diffstat (limited to '')
| -rw-r--r-- | test/bun.js/node-crypto.test.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/bun.js/node-crypto.test.js b/test/bun.js/node-crypto.test.js index 227368760..151a06198 100644 --- a/test/bun.js/node-crypto.test.js +++ b/test/bun.js/node-crypto.test.js @@ -15,3 +15,12 @@ it("crypto.createHash ", () => { for (let i = 0; i < 10; i++) fn(); }); + +it("crypto.createHmac", () => { + const result = crypto + .createHmac("sha256", "key") + .update("message") + .digest("base64"); + + expect(result).toBe("bp7ym3X//Ft6uuUn1Y/a2y/kLnIZARl2kXNDBl9Y7Uo="); +}); |
