Skip to content

Commit

Permalink
ts-web/core: hdkey test set up global web crypto
Browse files Browse the repository at this point in the history
  • Loading branch information
pro-wh committed Oct 16, 2024
1 parent 9e43884 commit aef8c27
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions client-sdk/ts-web/core/test/hdkey.test.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
import {webcrypto} from 'crypto';

import {HDKey} from '../src/hdkey';
import {concat, toHex} from '../src/misc';
import {WebCryptoSigner} from '../src/signature';

import * as adr0008VectorsRaw from './adr-0008-vectors.json';

if (typeof crypto === 'undefined') {
// @ts-expect-error there are some inconsequential type differences
globalThis.crypto = webcrypto;
}

interface Adr0008Vector {
kind: string;
bip39_mnemonic: string;
Expand Down

0 comments on commit aef8c27

Please sign in to comment.