Skip to content

Commit dfca3a1

Browse files
authored
Merge pull request #9006 from BitGo/WCN-685/external-signing-type-advanced
feat: add 'advanced' wallet generation in type
2 parents ab43513 + 9a5888d commit dfca3a1

2 files changed

Lines changed: 13 additions & 1 deletion

File tree

modules/sdk-core/src/bitgo/wallet/iWallets.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ export interface GenerateWalletOptions {
101101
isDistributedCustody?: boolean;
102102
bitgoKeyId?: string;
103103
commonKeychain?: string;
104-
type?: 'hot' | 'cold' | 'custodial' | 'trading';
104+
type?: 'hot' | 'cold' | 'custodial' | 'trading' | 'advanced';
105105
subType?: 'lightningCustody' | 'lightningSelfCustody';
106106
evmKeyRingReferenceWalletId?: string;
107107
lightningProvider?: 'amboss' | 'voltage';

modules/sdk-core/test/unit/bitgo/wallet/walletsExternalSigner.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,18 @@ describe('Wallets - external signer onchain wallet generation', function () {
102102
assert.strictEqual(result.bitgoKeychain.pub, bitgoPub);
103103
});
104104

105+
it('should pass advanced wallet type through to wallet/add', async function () {
106+
await wallets.generateWalletWithExternalSigner({
107+
label: 'Advanced Wallet',
108+
enterprise: 'enterprise-id',
109+
type: 'advanced',
110+
createKeychainCallback,
111+
});
112+
113+
const walletBody = sendStub.firstCall.args[0];
114+
walletBody.type.should.equal('advanced');
115+
});
116+
105117
it('should reject when callback source does not match requested source', async function () {
106118
createKeychainCallback.withArgs({ source: 'user', coin: 'tbtc' }).resolves({
107119
pub: userPub,

0 commit comments

Comments
 (0)