The Blockchain object keeps the state of all accounts and contracts.
Core symbol of the chain object (EOS, TLOS, WAX ...)
Token supply of coreSymbol
Reference to eosjs api interface
Reference to eosjs rpc interface
List of accounts created
Amount of time skipped
Local port number the RPC api is bound to
Setup new testing chain, setup chain docker instance, initialize api client, creates the following 10 test accounts:
- acc11.test
- acc12.test
- acc13.test
- acc14.test
- acc15.test
- acc21.test
- acc22.test
- acc23.test
- acc24.test
- acc25.test
Valid chainName values: WAX, EOS and TLOS
Clear chain after test, remove chain docker instance, relase docker port
A wrapper around the get_info RPC call.
Returns the head block number of the chain.
Checks if the chain is active and producing new blocks.
pushAction(action: Action, broadcast: boolean = true, sign: boolean = true, expireSeconds: number = 120): Promise<TransactResult | ReadOnlyTransactResult | PushTransactionArgs>
push action to chain.
pushActions(action: Action, broadcast: boolean = true, sign: boolean = true, expireSeconds: number = 120): Promise<TransactResult | ReadOnlyTransactResult | PushTransactionArgs>
push multiple actions to the chain in a single transaction.
Wait numblocks from the current block and returns a composite containing the startblock and the number of blocks that have elapsed.
Returns
{
startingBlock: Block
elapsedBlocks: 1
}
wait until chain produce target
block number