@@ -6,6 +6,7 @@ import { Dot, Tdot, KeyPair } from '../../src';
66import * as testData from '../fixtures' ;
77import { chainName , txVersion , genesisHash , specVersion } from '../resources' ;
88import * as sinon from 'sinon' ;
9+ import { Wallet } from '@bitgo/sdk-core' ;
910
1011describe ( 'DOT:' , function ( ) {
1112 let bitgo : TestBitGoAPI ;
@@ -646,4 +647,25 @@ describe('DOT:', function () {
646647 . should . rejectedWith ( 'Did not find address with funds to recover' ) ;
647648 } ) ;
648649 } ) ;
650+
651+ describe ( 'Verify Transaction' , function ( ) {
652+ const address1 = '5Ge59qRnZa8bxyhVFE6BDoY3kuhSrNVETRxXYLty1Hh6XTaf' ;
653+ const address2 = '5DiMLZugmcKEH3igPZP367FqummZkWeW5Z6zDCHLfxRjnPXe' ;
654+ it ( 'should reject a txPrebuild with more than one recipient' , async function ( ) {
655+ const wallet = new Wallet ( bitgo , basecoin , { } ) ;
656+
657+ const txParams = {
658+ recipients : [
659+ { amount : '1000000000000' , address : address1 } ,
660+ { amount : '2500000000000' , address : address2 } ,
661+ ] ,
662+ wallet : wallet ,
663+ walletPassphrase : 'fakeWalletPassphrase' ,
664+ } ;
665+
666+ await basecoin
667+ . verifyTransaction ( { txParams } )
668+ . should . be . rejectedWith ( 'txParams should only have 1 recipient but 2 found' ) ;
669+ } ) ;
670+ } ) ;
649671} ) ;
0 commit comments