Skip to content

Commit

Permalink
Fix clippy errors
Browse files Browse the repository at this point in the history
  • Loading branch information
QuantumDancer committed Jul 13, 2023
1 parent d2eab76 commit b645b16
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
16 changes: 8 additions & 8 deletions auditor/src/client/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ impl AuditorClient {
.send()
.await
{
Ok(s) => matches!(s.error_for_status(), Ok(_)),
Ok(s) => s.error_for_status().is_ok(),
Err(_) => false,
}
}
Expand Down Expand Up @@ -342,7 +342,7 @@ impl AuditorClientBlocking {
.get(format!("{}/health_check", &self.address))
.send()
{
Ok(s) => matches!(s.error_for_status(), Ok(_)),
Ok(s) => s.error_for_status().is_ok(),
Err(_) => false,
}
}
Expand Down Expand Up @@ -494,7 +494,7 @@ mod tests {

response
.into_iter()
.zip(body.into_iter())
.zip(body)
.map(|(rr, br)| assert_eq!(rr, br))
.count();
}
Expand Down Expand Up @@ -527,7 +527,7 @@ mod tests {

response
.into_iter()
.zip(body.into_iter())
.zip(body)
.map(|(rr, br)| assert_eq!(rr, br))
.count();
}
Expand Down Expand Up @@ -893,7 +893,7 @@ mod tests {

response
.into_iter()
.zip(body.into_iter())
.zip(body)
.map(|(rr, br)| assert_eq!(rr, br))
.count();
}
Expand Down Expand Up @@ -929,7 +929,7 @@ mod tests {

response
.into_iter()
.zip(body.into_iter())
.zip(body)
.map(|(rr, br)| assert_eq!(rr, br))
.count();
}
Expand Down Expand Up @@ -1007,7 +1007,7 @@ mod tests {

response
.into_iter()
.zip(body.into_iter())
.zip(body)
.map(|(rr, br)| assert_eq!(rr, br))
.count();
}
Expand Down Expand Up @@ -1043,7 +1043,7 @@ mod tests {

response
.into_iter()
.zip(body.into_iter())
.zip(body)
.map(|(rr, br)| assert_eq!(rr, br))
.count();
}
Expand Down
2 changes: 1 addition & 1 deletion auditor/src/domain/component.rs
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ impl PartialEq<Component> for ComponentTest {
&& s_amount.as_ref().unwrap() == o_amount.as_ref()
&& s_scores
.into_iter()
.zip(o_scores.into_iter())
.zip(o_scores)
.fold(true, |acc, (a, b)| acc && a == b)
}
}
Expand Down
4 changes: 2 additions & 2 deletions collectors/slurm/src/sacctcaller.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ use crate::{
type Job = HashMap<String, AllowedTypes>;

static BATCH_REGEX: Lazy<Regex> = Lazy::new(|| {
Regex::new(r#"^[0-9_]+\.batch$"#)
Regex::new(r"^[0-9_]+\.batch$")
.expect("Could not construct essential Regex for matching job ids.")
});

static SUB_REGEX: Lazy<Regex> = Lazy::new(|| {
Regex::new(r#"^[0-9]+\.[0-9]*$"#)
Regex::new(r"^[0-9]+\.[0-9]*$")
.expect("Could not construct essential Regex for matching job ids.")
});

Expand Down

0 comments on commit b645b16

Please sign in to comment.