Skip to content

Commit

Permalink
Fix clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
Jake Hartnell committed Mar 25, 2024
1 parent 14c6c0a commit 57123ce
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
8 changes: 4 additions & 4 deletions contracts/external/cw20-token/src/contract.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1045,7 +1045,7 @@ mod tests {
assert!(res.is_ok());
let query_minter_msg = QueryMsg::Minter {};
let res = query(deps.as_ref(), env, query_minter_msg);
let mint: MinterResponse = from_json(&res.unwrap()).unwrap();
let mint: MinterResponse = from_json(res.unwrap()).unwrap();

// Minter cannot update cap.
assert!(mint.cap == cap);
Expand Down Expand Up @@ -1095,7 +1095,7 @@ mod tests {
assert!(res.is_ok());
let query_minter_msg = QueryMsg::Minter {};
let res = query(deps.as_ref(), env, query_minter_msg);
let mint: Option<MinterResponse> = from_json(&res.unwrap()).unwrap();
let mint: Option<MinterResponse> = from_json(res.unwrap()).unwrap();

// Check that mint information was removed.
assert_eq!(mint, None);
Expand Down Expand Up @@ -1212,7 +1212,7 @@ mod tests {
QueryMsg::Balance { address: addr1 },
)
.unwrap();
let loaded: BalanceResponse = from_json(&data).unwrap();
let loaded: BalanceResponse = from_json(data).unwrap();
assert_eq!(loaded.balance, amount1);

// check balance query (empty)
Expand All @@ -1224,7 +1224,7 @@ mod tests {
},
)
.unwrap();
let loaded: BalanceResponse = from_json(&data).unwrap();
let loaded: BalanceResponse = from_json(data).unwrap();
assert_eq!(loaded.balance, Uint128::zero());
}

Expand Down
6 changes: 3 additions & 3 deletions contracts/external/cw20-token/src/enumerable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ mod tests {
limit: None,
};
let allowances: AllSpenderAllowancesResponse =
from_json(&query(deps.as_ref(), env.clone(), msg).unwrap()).unwrap();
from_json(query(deps.as_ref(), env.clone(), msg).unwrap()).unwrap();
assert_eq!(allowances.allowances.len(), 2);

// one is owner1 (order of CanonicalAddr uncorrelated with String)
Expand All @@ -230,7 +230,7 @@ mod tests {
limit: Some(1),
};
let allowances: AllSpenderAllowancesResponse =
from_json(&query(deps.as_ref(), env.clone(), msg).unwrap()).unwrap();
from_json(query(deps.as_ref(), env.clone(), msg).unwrap()).unwrap();
assert_eq!(allowances.allowances.len(), 1);
let allow = &allowances.allowances[0];
assert_eq!(&allow.owner, &owner1);
Expand All @@ -244,7 +244,7 @@ mod tests {
limit: Some(10000),
};
let allowances: AllSpenderAllowancesResponse =
from_json(&query(deps.as_ref(), env, msg).unwrap()).unwrap();
from_json(query(deps.as_ref(), env, msg).unwrap()).unwrap();
assert_eq!(allowances.allowances.len(), 1);
let allow = &allowances.allowances[0];
assert_eq!(&allow.owner, &owner2);
Expand Down

0 comments on commit 57123ce

Please sign in to comment.