Skip to content

Commit

Permalink
chore: make clippy happy
Browse files Browse the repository at this point in the history
  • Loading branch information
ctron committed Jul 30, 2024
1 parent 43bd3a4 commit 65da018
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ url = "2"
[features]
default = ["reqwest/default-tls"]
rustls-tls = ["reqwest/rustls-tls", "tokio-tungstenite/rustls"]
gaggle = []

[dev-dependencies]
httpmock = "0.6"
Expand Down
18 changes: 9 additions & 9 deletions src/goose.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3081,7 +3081,7 @@ mod tests {

let mut scenario = scenario!("foo");
assert_eq!(scenario.name, "foo");
assert_eq!(scenario.scenarios_index, usize::max_value());
assert_eq!(scenario.scenarios_index, usize::MAX);
assert_eq!(scenario.weight, 1);
assert_eq!(scenario.transaction_wait, None);
assert!(scenario.host.is_none());
Expand All @@ -3094,7 +3094,7 @@ mod tests {
scenario = scenario.register_transaction(transaction!(test_function_a));
assert_eq!(scenario.transactions.len(), 1);
assert_eq!(scenario.weighted_transactions.len(), 0);
assert_eq!(scenario.scenarios_index, usize::max_value());
assert_eq!(scenario.scenarios_index, usize::MAX);
assert_eq!(scenario.weight, 1);
assert_eq!(scenario.transaction_wait, None);
assert!(scenario.host.is_none());
Expand All @@ -3103,7 +3103,7 @@ mod tests {
scenario = scenario.register_transaction(transaction!(test_function_b));
assert_eq!(scenario.transactions.len(), 2);
assert_eq!(scenario.weighted_transactions.len(), 0);
assert_eq!(scenario.scenarios_index, usize::max_value());
assert_eq!(scenario.scenarios_index, usize::MAX);
assert_eq!(scenario.weight, 1);
assert_eq!(scenario.transaction_wait, None);
assert!(scenario.host.is_none());
Expand All @@ -3112,7 +3112,7 @@ mod tests {
scenario = scenario.register_transaction(transaction!(test_function_a));
assert_eq!(scenario.transactions.len(), 3);
assert_eq!(scenario.weighted_transactions.len(), 0);
assert_eq!(scenario.scenarios_index, usize::max_value());
assert_eq!(scenario.scenarios_index, usize::MAX);
assert_eq!(scenario.weight, 1);
assert_eq!(scenario.transaction_wait, None);
assert!(scenario.host.is_none());
Expand All @@ -3122,7 +3122,7 @@ mod tests {
assert_eq!(scenario.weight, 50);
assert_eq!(scenario.transactions.len(), 3);
assert_eq!(scenario.weighted_transactions.len(), 0);
assert_eq!(scenario.scenarios_index, usize::max_value());
assert_eq!(scenario.scenarios_index, usize::MAX);
assert_eq!(scenario.transaction_wait, None);
assert!(scenario.host.is_none());

Expand All @@ -3136,7 +3136,7 @@ mod tests {
assert_eq!(scenario.weight, 5);
assert_eq!(scenario.transactions.len(), 3);
assert_eq!(scenario.weighted_transactions.len(), 0);
assert_eq!(scenario.scenarios_index, usize::max_value());
assert_eq!(scenario.scenarios_index, usize::MAX);
assert_eq!(scenario.transaction_wait, None);

// Host field can be changed.
Expand All @@ -3155,7 +3155,7 @@ mod tests {
assert_eq!(scenario.weight, 5);
assert_eq!(scenario.transactions.len(), 3);
assert_eq!(scenario.weighted_transactions.len(), 0);
assert_eq!(scenario.scenarios_index, usize::max_value());
assert_eq!(scenario.scenarios_index, usize::MAX);

// Wait time can be changed.
scenario = scenario
Expand All @@ -3178,7 +3178,7 @@ mod tests {

// Initialize scenario.
let mut transaction = transaction!(test_function_a);
assert_eq!(transaction.transactions_index, usize::max_value());
assert_eq!(transaction.transactions_index, usize::MAX);
assert_eq!(transaction.name, "".to_string());
assert_eq!(transaction.weight, 1);
assert_eq!(transaction.sequence, 0);
Expand Down Expand Up @@ -3254,7 +3254,7 @@ mod tests {
let base_url = get_base_url(Some(HOST.to_string()), None, None).unwrap();
let user = GooseUser::new(0, "".to_string(), base_url, &configuration, 0, None).unwrap();
assert_eq!(user.scenarios_index, 0);
assert_eq!(user.weighted_users_index, usize::max_value());
assert_eq!(user.weighted_users_index, usize::MAX);

// Confirm the URLs are correctly built using the default_host.
let url = user.build_url("/foo").unwrap();
Expand Down

0 comments on commit 65da018

Please sign in to comment.