@@ -63,8 +63,8 @@ describe('DragonchainClient', () => {
6363 headers : {
6464 dragonchain : 'fakeDragonchainId' ,
6565 Authorization : 'fakeCreds' ,
66- timestamp : fakeTime
67- }
66+ timestamp : fakeTime ,
67+ } ,
6868 } ;
6969 } ) ;
7070
@@ -154,7 +154,7 @@ describe('DragonchainClient', () => {
154154 offset : 1 ,
155155 idsOnly : false ,
156156 sortAscending : false ,
157- sortBy : 'whatever'
157+ sortBy : 'whatever' ,
158158 } ) ;
159159 assert . calledWith (
160160 fetch ,
@@ -166,7 +166,7 @@ describe('DragonchainClient', () => {
166166 it ( 'defaults offset and limit' , async ( ) => {
167167 await client . queryTransactions ( {
168168 transactionType : 'test' ,
169- redisearchQuery : 'yeah'
169+ redisearchQuery : 'yeah' ,
170170 } ) ;
171171 assert . calledWith ( fetch , 'fakeUrl/v1/transaction?transaction_type=test&q=yeah&offset=0&limit=10' , expectedFetchOptions ) ;
172172 } ) ;
@@ -180,7 +180,7 @@ describe('DragonchainClient', () => {
180180
181181 it ( 'defaults offset and limit' , async ( ) => {
182182 await client . queryBlocks ( {
183- redisearchQuery : 'yeah'
183+ redisearchQuery : 'yeah' ,
184184 } ) ;
185185 assert . calledWith ( fetch , 'fakeUrl/v1/block?q=yeah&offset=0&limit=10' , expectedFetchOptions ) ;
186186 } ) ;
@@ -241,9 +241,9 @@ describe('DragonchainClient', () => {
241241 headers : {
242242 dragonchain : 'fakeDragonchainId' ,
243243 Authorization : 'fakeCreds' ,
244- timestamp : fakeTime
244+ timestamp : fakeTime ,
245245 } ,
246- body : undefined
246+ body : undefined ,
247247 } ;
248248
249249 describe ( '.deleteSmartContract' , ( ) => {
@@ -291,8 +291,8 @@ describe('DragonchainClient', () => {
291291 'Content-Type' : 'application/json' ,
292292 dragonchain : 'fakeDragonchainId' ,
293293 Authorization : 'fakeCreds' ,
294- timestamp : fakeTime
295- }
294+ timestamp : fakeTime ,
295+ } ,
296296 } ;
297297
298298 describe ( '.createApiKey' , ( ) => {
@@ -308,13 +308,13 @@ describe('DragonchainClient', () => {
308308 const transactionCreatePayload = {
309309 transactionType : 'transaction' ,
310310 payload : 'hi!' ,
311- tag : 'Awesome!'
311+ tag : 'Awesome!' ,
312312 } ;
313313 const expectedBody = {
314314 version : '1' ,
315315 txn_type : transactionCreatePayload . transactionType ,
316316 payload : transactionCreatePayload . payload ,
317- tag : transactionCreatePayload . tag
317+ tag : transactionCreatePayload . tag ,
318318 } ;
319319 await client . createTransaction ( transactionCreatePayload ) ;
320320 const obj = { ...expectedFetchOptions , body : JSON . stringify ( expectedBody ) } ;
@@ -335,14 +335,14 @@ describe('DragonchainClient', () => {
335335 options : {
336336 no_index : false ,
337337 weight : 0.5 ,
338- sortable : true
339- }
340- }
341- ]
338+ sortable : true ,
339+ } ,
340+ } ,
341+ ] ,
342342 } ;
343343 await client . createTransactionType ( {
344344 transactionType : 'testing' ,
345- customIndexFields : [ { path : 'testPath' , fieldName : 'someField' , type : 'text' , options : { noIndex : false , sortable : true , weight : 0.5 } } ]
345+ customIndexFields : [ { path : 'testPath' , fieldName : 'someField' , type : 'text' , options : { noIndex : false , sortable : true , weight : 0.5 } } ] ,
346346 } ) ;
347347 const obj = { ...expectedFetchOptions , body : JSON . stringify ( expectedBody ) } ;
348348 assert . calledWith ( fetch , 'fakeUrl/v1/transaction-type' , obj ) ;
@@ -356,7 +356,7 @@ describe('DragonchainClient', () => {
356356 image : 'ubuntu:latest' ,
357357 environmentVariables : { banana : 'banana' , apple : 'banana' } ,
358358 cmd : 'banana' ,
359- args : [ '-m' , 'cool' ]
359+ args : [ '-m' , 'cool' ] ,
360360 } ;
361361 const expectedBody = {
362362 version : '3' ,
@@ -365,7 +365,7 @@ describe('DragonchainClient', () => {
365365 execution_order : 'parallel' ,
366366 cmd : contractPayload . cmd ,
367367 args : contractPayload . args ,
368- env : contractPayload . environmentVariables
368+ env : contractPayload . environmentVariables ,
369369 } ;
370370 await client . createSmartContract ( contractPayload ) ;
371371 const obj = { ...expectedFetchOptions , body : JSON . stringify ( expectedBody ) } ;
@@ -381,7 +381,7 @@ describe('DragonchainClient', () => {
381381 value : '0x0' ,
382382 data : '0x111' ,
383383 gasPrice : '0x222' ,
384- gas : '0x333'
384+ gas : '0x333' ,
385385 } ;
386386 const expectedBody = {
387387 network : transactionCreatePayload . network ,
@@ -390,8 +390,8 @@ describe('DragonchainClient', () => {
390390 value : transactionCreatePayload . value ,
391391 data : transactionCreatePayload . data ,
392392 gasPrice : transactionCreatePayload . gasPrice ,
393- gas : transactionCreatePayload . gas
394- }
393+ gas : transactionCreatePayload . gas ,
394+ } ,
395395 } ;
396396 await client . createEthereumTransaction ( transactionCreatePayload ) ;
397397 const obj = { ...expectedFetchOptions , body : JSON . stringify ( expectedBody ) } ;
@@ -408,7 +408,7 @@ describe('DragonchainClient', () => {
408408 private_key : 'abcd' ,
409409 rpc_address : 'some rpc' ,
410410 rpc_authorization : 'some auth' ,
411- utxo_scan : false
411+ utxo_scan : false ,
412412 } ;
413413 await client . createBitcoinInterchain ( { name : 'banana' , testnet : true , privateKey : 'abcd' , rpcAddress : 'some rpc' , rpcAuthorization : 'some auth' , utxoScan : false } ) ;
414414 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -423,7 +423,7 @@ describe('DragonchainClient', () => {
423423 name : 'banana' ,
424424 private_key : 'private key' ,
425425 rpc_address : 'some rpc' ,
426- chain_id : 12
426+ chain_id : 12 ,
427427 } ;
428428 await client . createEthereumInterchain ( { name : 'banana' , privateKey : 'private key' , rpcAddress : 'some rpc' , chainId : 12 } ) ;
429429 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -440,7 +440,7 @@ describe('DragonchainClient', () => {
440440 private_key : 'abcd' ,
441441 node_url : 'some IP' ,
442442 rpc_port : 1234 ,
443- api_port : 5678
443+ api_port : 5678 ,
444444 } ;
445445 await client . createBinanceInterchain ( { name : 'banana' , testnet : true , privateKey : 'abcd' , nodeURL : 'some IP' , rpcPort : 1234 , apiPort : 5678 } ) ;
446446 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -455,7 +455,7 @@ describe('DragonchainClient', () => {
455455 fee : 4 ,
456456 data : 'someData' ,
457457 change : 'change address' ,
458- outputs : [ { to : 'toaddr' , value : 1.234 } ]
458+ outputs : [ { to : 'toaddr' , value : 1.234 } ] ,
459459 } ;
460460 await client . signBitcoinTransaction ( { name : 'banana' , satoshisPerByte : 4 , data : 'someData' , changeAddress : 'change address' , outputs : [ { to : 'toaddr' , value : 1.234 } ] } ) ;
461461 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -472,7 +472,7 @@ describe('DragonchainClient', () => {
472472 data : 'someData' ,
473473 gasPrice : 'gas price' ,
474474 gas : 'gas' ,
475- nonce : 'nonce'
475+ nonce : 'nonce' ,
476476 } ;
477477 await client . signEthereumTransaction ( { name : 'banana' , to : 'some addr' , value : 'some value' , data : 'someData' , gasPrice : 'gas price' , gas : 'gas' , nonce : 'nonce' } ) ;
478478 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -487,7 +487,7 @@ describe('DragonchainClient', () => {
487487 amount : 123 ,
488488 to_address : 'receiver addy' ,
489489 symbol : 'TOKEN' ,
490- memo : 'for bananas'
490+ memo : 'for bananas' ,
491491 } ;
492492 await client . signBinanceTransaction ( { name : 'banana' , amount : 123 , toAddress : 'receiver addy' , symbol : 'TOKEN' , memo : 'for bananas' } ) ;
493493 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -500,7 +500,7 @@ describe('DragonchainClient', () => {
500500 const fakeBody : any = {
501501 version : '1' ,
502502 blockchain : 'bitcoin' ,
503- name : 'banana'
503+ name : 'banana' ,
504504 } ;
505505 await client . setDefaultInterchainNetwork ( { name : 'banana' , blockchain : 'bitcoin' } ) ;
506506 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -514,7 +514,7 @@ describe('DragonchainClient', () => {
514514 version : '1' ,
515515 blockchain : 'bitcoin' ,
516516 name : 'banana' ,
517- signed_txn : 'banana'
517+ signed_txn : 'banana' ,
518518 } ;
519519 await client . publishInterchainTransaction ( { name : 'banana' , blockchain : 'bitcoin' , signedTransaction : 'banana' } ) ;
520520 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -539,8 +539,8 @@ describe('DragonchainClient', () => {
539539 'Content-Type' : 'application/json' ,
540540 dragonchain : 'fakeDragonchainId' ,
541541 Authorization : 'fakeCreds' ,
542- timestamp : fakeTime
543- }
542+ timestamp : fakeTime ,
543+ } ,
544544 } ;
545545
546546 describe ( '.updateApiKey' , ( ) => {
@@ -557,7 +557,7 @@ describe('DragonchainClient', () => {
557557 const status = 'active' ;
558558 const fakeBodyResponse : any = {
559559 version : '3' ,
560- desired_state : status
560+ desired_state : status ,
561561 } ;
562562 await client . updateSmartContract ( { smartContractId, enabled : true } ) ;
563563 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBodyResponse ) } ;
@@ -582,8 +582,8 @@ describe('DragonchainClient', () => {
582582 'Content-Type' : 'application/json' ,
583583 dragonchain : 'fakeDragonchainId' ,
584584 Authorization : 'fakeCreds' ,
585- timestamp : fakeTime
586- }
585+ timestamp : fakeTime ,
586+ } ,
587587 } ;
588588
589589 describe ( '.updateBitcoinInterchain' , ( ) => {
@@ -594,7 +594,7 @@ describe('DragonchainClient', () => {
594594 private_key : 'abcd' ,
595595 rpc_address : 'some rpc' ,
596596 rpc_authorization : 'some auth' ,
597- utxo_scan : false
597+ utxo_scan : false ,
598598 } ;
599599 await client . updateBitcoinInterchain ( { name : 'banana' , testnet : true , privateKey : 'abcd' , rpcAddress : 'some rpc' , rpcAuthorization : 'some auth' , utxoScan : false } ) ;
600600 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -608,7 +608,7 @@ describe('DragonchainClient', () => {
608608 version : '1' ,
609609 private_key : 'abcd' ,
610610 rpc_address : 'some rpc' ,
611- chain_id : 12
611+ chain_id : 12 ,
612612 } ;
613613 await client . updateEthereumInterchain ( { name : 'banana' , privateKey : 'abcd' , rpcAddress : 'some rpc' , chainId : 12 } ) ;
614614 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
@@ -624,7 +624,7 @@ describe('DragonchainClient', () => {
624624 private_key : 'abcd' ,
625625 node_url : 'some IP' ,
626626 rpc_port : 1234 ,
627- api_port : 5678
627+ api_port : 5678 ,
628628 } ;
629629 await client . updateBinanceInterchain ( { name : 'banana' , testnet : true , privateKey : 'abcd' , nodeURL : 'some IP' , rpcPort : 1234 , apiPort : 5678 } ) ;
630630 const obj = { ...expectedFetchOptions , body : JSON . stringify ( fakeBody ) } ;
0 commit comments