mirror of
https://github.com/Xahau/xahau.js.git
synced 2025-11-19 03:35:49 +00:00
28 lines
753 B
TypeScript
28 lines
753 B
TypeScript
import _ from 'lodash'
|
|
import { Payment } from 'xrpl-local'
|
|
|
|
import serverUrl from '../serverUrl'
|
|
import { setupClient, teardownClient } from '../setup'
|
|
import { generateFundedWallet, testTransaction } from '../utils'
|
|
|
|
// how long before each test case times out
|
|
const TIMEOUT = 20000
|
|
|
|
describe('Payment', function () {
|
|
this.timeout(TIMEOUT)
|
|
|
|
beforeEach(_.partial(setupClient, serverUrl))
|
|
afterEach(teardownClient)
|
|
|
|
it('base', async function () {
|
|
const wallet2 = await generateFundedWallet(this.client)
|
|
const tx: Payment = {
|
|
TransactionType: 'Payment',
|
|
Account: this.wallet.classicAddress,
|
|
Destination: wallet2.classicAddress,
|
|
Amount: '1000',
|
|
}
|
|
await testTransaction(this.client, tx, this.wallet)
|
|
})
|
|
})
|