Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LPv2: Bump-up foreign investment. Fix failing investment ITs #1934

Merged
merged 13 commits into from
Aug 1, 2024
24 changes: 11 additions & 13 deletions runtime/integration-tests/src/cases/liquidity_pools.rs
Original file line number Diff line number Diff line change
Expand Up @@ -156,9 +156,7 @@ mod utils {
token_name: BoundedVec::<
u8,
<T as pallet_pool_system::Config>::StringLimit,
>::try_from(
"A highly advanced tranche".as_bytes().to_vec()
)
>::try_from("A highly advanced tranche".as_bytes().to_vec())
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this breaks cargo fmt?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, already fixed. I don't know why but my IDE Rustrover keeps introducing this fmt error and I can only commit the fixed version manually without the IDE.... Small indie company JetBrains..

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could it be done regarding the cargo version?

For me, what's works as CI is cargo +nightly fmt which is the action I've configured in my IDE

.expect("Can create BoundedVec for token name"),
token_symbol: BoundedVec::<
u8,
Expand Down Expand Up @@ -695,7 +693,7 @@ mod foreign_investments {
mod same_currencies {
use super::*;

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn increase_deposit_request<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down Expand Up @@ -747,7 +745,7 @@ mod foreign_investments {
});
}

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn decrease_deposit_request<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down Expand Up @@ -837,7 +835,7 @@ mod foreign_investments {
});
}

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn cancel_deposit_request<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down Expand Up @@ -937,7 +935,7 @@ mod foreign_investments {
});
}

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn collect_deposit_request<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down Expand Up @@ -1078,7 +1076,7 @@ mod foreign_investments {
});
}

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn collect_investment<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down Expand Up @@ -1301,7 +1299,7 @@ mod foreign_investments {
});
}

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn increase_redeem_request<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down Expand Up @@ -1354,7 +1352,7 @@ mod foreign_investments {
});
}

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn cancel_redeem_request<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down Expand Up @@ -1449,7 +1447,7 @@ mod foreign_investments {
});
}

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn collect_redeem_request<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down Expand Up @@ -1631,7 +1629,7 @@ mod foreign_investments {
mod should_throw_requires_collect {
use super::*;

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn invest_requires_collect<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down Expand Up @@ -1862,7 +1860,7 @@ mod foreign_investments {
mod mismatching_currencies {
use super::*;

#[test_runtimes([centrifuge, development])]
#[test_runtimes([development])]
fn collect_foreign_investment_for<T: Runtime + FudgeSupport>() {
let mut env = FudgeEnv::<T>::from_parachain_storage(
Genesis::default()
Expand Down
Loading