mirror of
https://github.com/Xahau/xahau.js.git
synced 2025-11-29 16:45:49 +00:00
Add Ledger Method Integration Tests (#1640)
Add integration tests for ledger, ledgerEntry, ledgerData, ledgerClosed and ledgerCurrent, plus add them to the browser tests.
This commit is contained in:
committed by
Mayukha Vadari
parent
5d67f14ea3
commit
297dee9b8f
@@ -2,7 +2,7 @@ import { assert } from 'chai'
|
||||
import _ from 'lodash'
|
||||
import { decode } from 'ripple-binary-codec'
|
||||
|
||||
import { Client, Wallet } from 'xrpl-local'
|
||||
import { Client, Wallet, Response } from 'xrpl-local'
|
||||
import { Payment, Transaction } from 'xrpl-local/models/transactions'
|
||||
import { computeSignedTransactionHash } from 'xrpl-local/utils/hashes'
|
||||
|
||||
@@ -73,6 +73,11 @@ export async function verifySubmittedTransaction(
|
||||
}
|
||||
}
|
||||
|
||||
export function verifySuccessfulResponse(response: Response): void {
|
||||
assert.equal(response.status, 'success')
|
||||
assert.equal(response.type, 'response')
|
||||
}
|
||||
|
||||
export async function testTransaction(
|
||||
client: Client,
|
||||
transaction: Transaction,
|
||||
|
||||
Reference in New Issue
Block a user