@@ -33,6 +33,7 @@ import {
3333 tupleCV ,
3434} from '@stacks/transactions' ;
3535import { RPCClient } from 'rpc-bitcoin' ;
36+ import { getRosettaNetworkName , RosettaConstants } from '../api/rosetta-constants' ;
3637
3738import {
3839 ClarityTypeID ,
@@ -41,7 +42,6 @@ import {
4142} from 'stacks-encoding-native-js' ;
4243import * as supertest from 'supertest' ;
4344import { ApiServer } from '../api/init' ;
44- import { getRosettaNetworkName , RosettaConstants } from '../api/rosetta-constants' ;
4545import { testnetKeys } from '../api/routes/debug' ;
4646import { CoreRpcPoxInfo , StacksCoreRpcClient } from '../core-rpc/client' ;
4747import { DbBlock , DbTx , DbTxStatus } from '../datastore/common' ;
@@ -211,7 +211,8 @@ export async function standByUntilBurnBlock(burnBlockHeight: number): Promise<Db
211211 return dbBlock ;
212212}
213213
214- export async function standByForTx ( expectedTxId : string ) : Promise < DbTx > {
214+ // todo: add `export` to this and remove other implementations of this
215+ async function standByForTx ( expectedTxId : string ) : Promise < DbTx > {
215216 const tx = await new Promise < DbTx > ( async resolve => {
216217 const listener : ( txId : string ) => void = async txId => {
217218 if ( txId !== expectedTxId ) {
@@ -262,7 +263,8 @@ export async function standByForTxSuccess(expectedTxId: string): Promise<DbTx> {
262263 return tx ;
263264}
264265
265- export async function standByUntilBlock ( blockHeight : number ) : Promise < DbBlock > {
266+ // todo: add `export` to this and remove other implementations of this
267+ async function standByUntilBlock ( blockHeight : number ) : Promise < DbBlock > {
266268 const dbBlock = await new Promise < DbBlock > ( async resolve => {
267269 const listener : ( blockHash : string ) => void = async blockHash => {
268270 const dbBlockQuery = await testEnv . api . datastore . getBlock ( { hash : blockHash } ) ;
@@ -371,7 +373,8 @@ export async function readOnlyFnCall<T extends NativeClarityValue>(
371373 return decodedVal ;
372374}
373375
374- export async function fetchRosetta < TPostBody , TRes > ( endpoint : string , body : TPostBody ) {
376+ // todo: add `export` to this and remove other implementations of this
377+ async function fetchRosetta < TPostBody , TRes > ( endpoint : string , body : TPostBody ) {
375378 const result = await supertest ( testEnv . api . server )
376379 . post ( endpoint )
377380 . send ( body as any ) ;
0 commit comments