Skip to content

Commit 598dbe6

Browse files
Fix Node 18 tests
1 parent aa4796a commit 598dbe6

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

packages/wallet/src/Wallet.test.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,13 @@ describe('Wallet', () => {
2424
// We can remove this once we drop Node 18
2525
// eslint-disable-next-line n/no-unsupported-features/node-builtins
2626
globalThis.crypto ??= webcrypto as typeof globalThis.crypto;
27+
28+
// eslint-disable-next-line no-restricted-syntax
29+
if (!('CryptoKey' in globalThis)) {
30+
Object.defineProperty(globalThis, 'CryptoKey', {
31+
value: webcrypto.CryptoKey,
32+
});
33+
}
2734
});
2835

2936
it('exposes state', async () => {

0 commit comments

Comments
 (0)