fix: make sol-to-lamport const name more clear
This commit is contained in:
committed by
Michael Vines
parent
eef794d9be
commit
b2243802b5
@@ -1,5 +1,5 @@
|
||||
// @flow
|
||||
import {Account, Connection, SystemProgram, SOL_LAMPORTS} from '../src';
|
||||
import {Account, Connection, SystemProgram, LAMPORTS_PER_SOL} from '../src';
|
||||
import {mockRpc, mockRpcEnabled} from './__mocks__/node-fetch';
|
||||
import {mockGetRecentBlockhash} from './mockrpc/get-recent-blockhash';
|
||||
import {url} from './url';
|
||||
@@ -22,7 +22,7 @@ test('transaction-payer', async () => {
|
||||
method: 'requestAirdrop',
|
||||
params: [
|
||||
accountPayer.publicKey.toBase58(),
|
||||
SOL_LAMPORTS,
|
||||
LAMPORTS_PER_SOL,
|
||||
{commitment: 'recent'},
|
||||
],
|
||||
},
|
||||
@@ -32,7 +32,7 @@ test('transaction-payer', async () => {
|
||||
'0WE5w4B7v59x6qjyC4FbG2FEKYKQfvsJwqSxNVmtMjT8TQ31hsZieDHcSgqzxiAoTL56n2w5TncjqEKjLhtF4Vk',
|
||||
},
|
||||
]);
|
||||
await connection.requestAirdrop(accountPayer.publicKey, SOL_LAMPORTS);
|
||||
await connection.requestAirdrop(accountPayer.publicKey, LAMPORTS_PER_SOL);
|
||||
|
||||
mockRpc.push([
|
||||
url,
|
||||
@@ -147,7 +147,7 @@ test('transaction-payer', async () => {
|
||||
// (exact amount less depends on the current cluster fees)
|
||||
const balance = await connection.getBalance(accountPayer.publicKey);
|
||||
expect(balance).toBeGreaterThan(0);
|
||||
expect(balance).toBeLessThanOrEqual(SOL_LAMPORTS);
|
||||
expect(balance).toBeLessThanOrEqual(LAMPORTS_PER_SOL);
|
||||
|
||||
// accountFrom should have exactly 2, since it didn't pay for the transaction
|
||||
mockRpc.push([
|
||||
|
Reference in New Issue
Block a user