From 8262a81cb24f27e7d0f4a0215a2acea7b014a19a Mon Sep 17 00:00:00 2001 From: fiatjaf Date: Wed, 21 Dec 2022 17:12:50 -0300 Subject: [PATCH] make crypto available as a global on nip04 test. --- nip04.test.js | 1 + 1 file changed, 1 insertion(+) diff --git a/nip04.test.js b/nip04.test.js index 90a4380..897c58c 100644 --- a/nip04.test.js +++ b/nip04.test.js @@ -1,5 +1,6 @@ /* eslint-env jest */ +globalThis.crypto = require('crypto') const {nip04, getPublicKey, generatePrivateKey} = require('./lib/nostr.cjs') test('encrypt and decrypt message', async () => {