Skip to content

Commit

Permalink
Fix ledger_txs_and_queries
Browse files Browse the repository at this point in the history
  • Loading branch information
sug0 committed May 6, 2024
1 parent 0d40c77 commit e6488ac
Showing 1 changed file with 72 additions and 11 deletions.
83 changes: 72 additions & 11 deletions crates/tests/src/integration/ledger_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ use test_log::test;

use crate::e2e::ledger_tests::prepare_proposal_data;
use crate::e2e::setup::constants::{
ALBERT, ALBERT_KEY, BERTHA, BERTHA_KEY, CHRISTEL, CHRISTEL_KEY, DAEWON,
ESTER, GOVERNANCE_ADDRESS, NAM,
ALBERT, ALBERT_KEY, APFEL, BERTHA, BERTHA_KEY, BTC, CHRISTEL, CHRISTEL_KEY,
DAEWON, DOT, ESTER, ETH, GOVERNANCE_ADDRESS, KARTOFFEL, NAM, SCHNITZEL,
};
use crate::integration::helpers::{
find_address, prepare_steward_commission_update_data,
Expand Down Expand Up @@ -209,19 +209,80 @@ fn ledger_txs_and_queries() -> Result<()> {
// expect a decimal
vec![r"nam: \d+(\.\d+)?"],
),
// Unspecified token expect all tokens from wallet derived from genesis
// Test balance of tokens generated at genesis
(
vec!["balance", "--owner", ALBERT, "--node", &validator_one_rpc],
// expect all genesis tokens, sorted by alias
vec![
r"apfel: \d+(\.\d+)?",
r"btc: \d+(\.\d+)?",
r"dot: \d+(\.\d+)?",
r"eth: \d+(\.\d+)?",
r"kartoffel: \d+(\.\d+)?",
r"schnitzel: \d+(\.\d+)?",
"balance",
"--owner",
ALBERT,
"--token",
APFEL,
"--node",
&validator_one_rpc,
],
vec![r"apfel: \d+(\.\d+)?"],
),
(
vec![
"balance",
"--owner",
ALBERT,
"--token",
BTC,
"--node",
&validator_one_rpc,
],
vec![r"btc: \d+(\.\d+)?"],
),
(
vec![
"balance",
"--owner",
ALBERT,
"--token",
DOT,
"--node",
&validator_one_rpc,
],
vec![r"dot: \d+(\.\d+)?"],
),
(
vec![
"balance",
"--owner",
ALBERT,
"--token",
ETH,
"--node",
&validator_one_rpc,
],
vec![r"eth: \d+(\.\d+)?"],
),
(
vec![
"balance",
"--owner",
ALBERT,
"--token",
KARTOFFEL,
"--node",
&validator_one_rpc,
],
vec![r"kartoffel: \d+(\.\d+)?"],
),
(
vec![
"balance",
"--owner",
ALBERT,
"--token",
SCHNITZEL,
"--node",
&validator_one_rpc,
],
vec![r"schnitzel: \d+(\.\d+)?"],
),
// Account query
(
vec![
"query-account",
Expand Down

0 comments on commit e6488ac

Please sign in to comment.