From e947cf94f39e95242a78750aa6181b0c57479c8a Mon Sep 17 00:00:00 2001 From: dzmitry-lahoda Date: Mon, 8 Apr 2024 22:32:30 +0100 Subject: [PATCH] fixing clippy --- contracts/cosmwasm/order/src/prelude.rs | 2 +- contracts/cosmwasm/order/src/types.rs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/contracts/cosmwasm/order/src/prelude.rs b/contracts/cosmwasm/order/src/prelude.rs index 8f439085..08ccea09 100644 --- a/contracts/cosmwasm/order/src/prelude.rs +++ b/contracts/cosmwasm/order/src/prelude.rs @@ -1,6 +1,6 @@ pub use cosmwasm_schema::cw_serde; pub use cosmwasm_std::{Addr, Coin}; -pub use cosmwasm_std::{StdError, Uint128, Uint64}; +pub use cosmwasm_std::{StdError, Uint128}; pub use tuples::*; pub use serde::{Deserialize, Serialize}; diff --git a/contracts/cosmwasm/order/src/types.rs b/contracts/cosmwasm/order/src/types.rs index fa16d2cd..d375bc69 100644 --- a/contracts/cosmwasm/order/src/types.rs +++ b/contracts/cosmwasm/order/src/types.rs @@ -95,13 +95,14 @@ pub struct Filling { #[cfg(test)] mod test { use cosmwasm_std::Coin; + use num_rational::Ratio; use crate::prelude::*; use crate::types::*; #[test] pub fn fill() { - let optimal_price = (Uint64::from(1u64), Uint64::from(1u64)); + let optimal_price = Ratio::new(1u64, 1u64); let mut order = OrderItem { owner: Addr::unchecked("owner".to_string()), msg: OrderSubMsg {