diff --git a/smart-contracts/osmosis/contracts/cl-vault/.cargo/config.toml b/smart-contracts/osmosis/contracts/cl-vault/.cargo/config.toml index e419b5264..aea3032f8 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/.cargo/config.toml +++ b/smart-contracts/osmosis/contracts/cl-vault/.cargo/config.toml @@ -4,5 +4,5 @@ unit-test = "test --lib" schema = "run --bin schema" # test-tube = "test --test * --features test-tube -- --test-threads=1" test-tube = "test --test test-tube --features test-tube -- --test-threads=1" -prop-test = "test --test prop-test --features test-tube -- --test-threads=1" +prop-test = "test --test prop-test --features test-tube -- --test-threads=1 --nocapture" test-tube-build = "build --release --lib --target wasm32-unknown-unknown --target-dir ./test-tube-build" diff --git a/smart-contracts/osmosis/contracts/cl-vault/Cargo.toml b/smart-contracts/osmosis/contracts/cl-vault/Cargo.toml index c0c97ea57..4fe5c01c2 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/Cargo.toml +++ b/smart-contracts/osmosis/contracts/cl-vault/Cargo.toml @@ -17,12 +17,12 @@ name = "schema" [[test]] name = "test-tube" -path = "tests/integration.rs" +path = "tests/test-tube/integration.rs" required-features = ["test-tube"] [[test]] name = "prop-test" -path = "tests/fuzzer.rs" +path = "tests/test-tube/fuzzer.rs" required-features = ["test-tube"] [features] diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/admin.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/admin.rs similarity index 97% rename from smart-contracts/osmosis/contracts/cl-vault/tests/admin.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/admin.rs index b83d52f82..90db90b93 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/tests/admin.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/admin.rs @@ -1,5 +1,3 @@ -#![cfg(feature = "test-tube")] - use crate::setup::{fixture_default, PERFORMANCE_FEE_DEFAULT}; use cl_vault::{ diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/any_deposit.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/any_deposit.rs similarity index 99% rename from smart-contracts/osmosis/contracts/cl-vault/tests/any_deposit.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/any_deposit.rs index 6d56142c8..9495e2380 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/tests/any_deposit.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/any_deposit.rs @@ -1,5 +1,3 @@ -#![cfg(feature = "test-tube")] - use crate::setup::{ fixture_dex_router, ACCOUNTS_INIT_BALANCE, ACCOUNTS_NUM, DENOM_BASE, DENOM_QUOTE, MAX_SLIPPAGE_HIGH, PERFORMANCE_FEE_DEFAULT, diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/authz.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/authz.rs similarity index 99% rename from smart-contracts/osmosis/contracts/cl-vault/tests/authz.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/authz.rs index a91cf6c0e..39f4a55e6 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/tests/authz.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/authz.rs @@ -1,5 +1,3 @@ -#![cfg(feature = "test-tube")] - use crate::setup::{ fixture_default, get_amount_from_denom, DENOM_BASE, DENOM_QUOTE, PERFORMANCE_FEE_DEFAULT, }; diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/autocompound.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/autocompound.rs similarity index 99% rename from smart-contracts/osmosis/contracts/cl-vault/tests/autocompound.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/autocompound.rs index 22b4998e6..d28680735 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/tests/autocompound.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/autocompound.rs @@ -1,5 +1,3 @@ -#![cfg(feature = "test-tube")] - use crate::setup::{ calculate_expected_refunds, fixture_dex_router, get_balance_amount, get_event_attributes_by_ty_and_key, ACCOUNTS_INIT_BALANCE, ACCOUNTS_NUM, DENOM_BASE, diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/deposit_withdraw.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/deposit_withdraw.rs similarity index 99% rename from smart-contracts/osmosis/contracts/cl-vault/tests/deposit_withdraw.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/deposit_withdraw.rs index 5f7ff3dc7..893339ec2 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/tests/deposit_withdraw.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/deposit_withdraw.rs @@ -1,5 +1,3 @@ -#![cfg(feature = "test-tube")] - use crate::setup::{ fixture_default, get_event_attributes_by_ty_and_key, ACCOUNTS_INIT_BALANCE, DENOM_BASE, DENOM_QUOTE, PERFORMANCE_FEE_DEFAULT, diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/fuzzer.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/fuzzer.rs similarity index 100% rename from smart-contracts/osmosis/contracts/cl-vault/tests/fuzzer.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/fuzzer.rs diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/initialize.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/initialize.rs similarity index 99% rename from smart-contracts/osmosis/contracts/cl-vault/tests/initialize.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/initialize.rs index 67d2b0e83..80715b16f 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/tests/initialize.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/initialize.rs @@ -1,5 +1,3 @@ -#![cfg(feature = "test-tube")] - use crate::setup::{ fixture_default, DENOM_BASE, DENOM_QUOTE, MAX_SLIPPAGE_HIGH, PERFORMANCE_FEE_DEFAULT, }; diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/integration.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/integration.rs similarity index 100% rename from smart-contracts/osmosis/contracts/cl-vault/tests/integration.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/integration.rs diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/proptest.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/proptest.rs similarity index 99% rename from smart-contracts/osmosis/contracts/cl-vault/tests/proptest.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/proptest.rs index b59d715b6..259e43720 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/tests/proptest.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/proptest.rs @@ -1,5 +1,3 @@ -#![cfg(feature = "test-tube")] - use crate::setup::{ get_event_attributes_by_ty_and_key, init_test_contract, MAX_SLIPPAGE_HIGH, PERFORMANCE_FEE_DEFAULT, @@ -337,7 +335,6 @@ proptest! { percentages in get_percentage_list(), account_indexes in get_account_index_list() ) { - println!("start"); let (app, contract_address, _cl_pool_id, admin_account, _deposit_ratio, _deposit_ratio_approx) = init_test_contract( "./test-tube-build/wasm32-unknown-unknown/release/cl_vault.wasm", &[ @@ -368,7 +365,6 @@ proptest! { Uint128::zero(), PERFORMANCE_FEE_DEFAULT ); - println!("wasm"); let wasm = Wasm::new(&app); let cl = ConcentratedLiquidity::new(&app); let bank = Bank::new(&app); @@ -387,7 +383,6 @@ proptest! { } for i in 0..ITERATIONS_NUMBER { - println!("iter"); match actions[i] { Action::Deposit => { deposit(&wasm, &bank, &contract_address, &accounts[account_indexes[i] as usize], percentages[i], DENOM_BASE, DENOM_QUOTE); diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/range.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/range.rs similarity index 99% rename from smart-contracts/osmosis/contracts/cl-vault/tests/range.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/range.rs index 7a505eb94..4763f3b6d 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/tests/range.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/range.rs @@ -1,5 +1,3 @@ -#![cfg(feature = "test-tube")] - use crate::setup::{ fixture_default, fixture_dex_router, init_test_contract, ADMIN_BALANCE_AMOUNT, DENOM_BASE, DENOM_QUOTE, MAX_SLIPPAGE_HIGH, PERFORMANCE_FEE_DEFAULT, diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/rewards.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/rewards.rs similarity index 100% rename from smart-contracts/osmosis/contracts/cl-vault/tests/rewards.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/rewards.rs diff --git a/smart-contracts/osmosis/contracts/cl-vault/tests/setup.rs b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/setup.rs similarity index 99% rename from smart-contracts/osmosis/contracts/cl-vault/tests/setup.rs rename to smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/setup.rs index f149c858a..c1e3bb11f 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/tests/setup.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/tests/test-tube/setup.rs @@ -1,4 +1,3 @@ -#![cfg(feature = "test-tube")] #![allow(dead_code)] use cl_vault::{helpers::generic::sort_tokens, msg::InstantiateMsg, state::VaultConfig};