Open
Description
This is a descriptor mainnet / xpub
generated by ColdCard wpkh([182551a3/84h/0h/0h]xpub6DM9LRnPTBFRREps8bsNhfGKZ9Phwz6QSWG4iwdxLF2jfMKCncXD7pMyZhjWXmD8QQGPa1ENYZuvV8shstsZmfpZKAXinpoweXCuNBMc5uz/<0;1>/*)#4f2pnnww
This combined descriptor should be either parsed or not parsed, but I found out that it's not parsed using bdk.Network.bitcoin
and it's properly parsed if I use bdk.Network.testnet
.
test('mainnet combined descriptor should work on mainnet', () async {
expect(() async {
await bdk.Descriptor.create(
descriptor: combinedDescriptor,
network: bdk.Network.bitcoin,
);
}, returnsNormally);
});
test('mainnet combined descriptor shouldnt work on testnet', () async {
expect(() async {
await bdk.Descriptor.create(
descriptor: combinedDescriptor,
network: bdk.Network.testnet,
);
}, throwsA(anything));
});
🔴
00:13 +6 -2: Integration Tests Descriptor mainnet combined descriptor should work on mainnet [E]
KeyException( Invalid network )
package:bdk_flutter/src/root.dart 298:7
🤯
00:13 +6 -3: Integration Tests Descriptor mainnet combined descriptor shouldnt work on testnet [E]
descriptor:
// properly parsed !
wpkh([182551a3/84'/0'/0']xpub6DM9LRnPTBFRREps8bsNhfGKZ9Phwz6QSWG4iwdxLF2jfMKCncXD7pMyZhjWXmD8QQGPa1ENYZuvV8shstsZmfpZKAXinpoweXCuNBMc5uz/<0;1>/*)#zph0ljyn
Expected: throws anything
Actual: <Closure: () => Future<Null>>
Which: returned a Future that emitted <null>
Metadata
Metadata
Assignees
Labels
No labels