mirror of
https://github.com/logos-blockchain/logos-execution-zone.git
synced 2026-08-25 11:21:12 +00:00
This PR introduces the initial Cucumber-based integration test framework for the LEZ, building on the testing-framework integration work started by @andrussal, adds the first set of Cucumber integration scenarios and establishes reusable infrastructure for future Cucumber scenarios. --------- Co-authored-by: Andrus Salumets <salumets.andrus@gmail.com> Co-authored-by: Sergio Chouhy <sergio.chouhy@gmail.com> Co-authored-by: Sergio Chouhy <41742639+schouhy@users.noreply.github.com> Co-authored-by: Roman <zajic@zajic.net> Co-authored-by: Daniil Polyakov <arjentix@gmail.com> Co-authored-by: Moudy <m.ellaz@hotmail.com> Co-authored-by: andrussal <salumets.andrus@gmail.com>
35 lines
1.0 KiB
Rust
35 lines
1.0 KiB
Rust
#![expect(
|
|
clippy::tests_outside_test_module,
|
|
reason = "We don't care about these in tests"
|
|
)]
|
|
|
|
use anyhow::Result;
|
|
use integration_tests::{
|
|
TestContext, fetch_privacy_preserving_tx, private_mention, utils::new_account,
|
|
};
|
|
use tokio::test;
|
|
use wallet::cli::{
|
|
Command, SubcommandReturnValue, programs::native_token_transfer::AuthTransferSubcommand,
|
|
};
|
|
|
|
#[test]
|
|
async fn private_transaction_pads_notes_to_max() -> Result<()> {
|
|
let mut ctx = TestContext::new().await?;
|
|
|
|
let account_id = new_account(&mut ctx, true, None).await?;
|
|
|
|
let command = Command::AuthTransfer(AuthTransferSubcommand::Init {
|
|
account_id: private_mention(account_id),
|
|
});
|
|
let result = wallet::cli::execute_subcommand(ctx.wallet_mut(), command).await?;
|
|
let SubcommandReturnValue::TransactionExecuted { tx_hash } = result else {
|
|
anyhow::bail!("Expected TransactionExecuted return value");
|
|
};
|
|
|
|
let tx = fetch_privacy_preserving_tx(ctx.sequencer_client(), tx_hash).await;
|
|
|
|
assert_eq!(tx.message.private_actions.len(), 7);
|
|
|
|
Ok(())
|
|
}
|