style: rustfmt the Phase 1 test additions

The per-file Phase 1 test commits were written without running rustfmt
as I went; this pass formats the new test code (long assert_eq! lines
wrapped, etc.). Formatting-only — no behavioural change.
This commit is contained in:
2026-05-14 03:41:38 -06:00
parent 2ca8d71b94
commit 6aee6d6318
29 changed files with 466 additions and 161 deletions
+32 -8
View File
@@ -766,19 +766,37 @@ mod tests {
a.constraint_violation = 0.0;
let mut b = Evaluation::new(vec![1.0]);
b.constraint_violation = 1.0;
assert_eq!(compare_so(&a, &b, Direction::Minimize), std::cmp::Ordering::Less);
assert_eq!(compare_so(&b, &a, Direction::Minimize), std::cmp::Ordering::Greater);
assert_eq!(
compare_so(&a, &b, Direction::Minimize),
std::cmp::Ordering::Less
);
assert_eq!(
compare_so(&b, &a, Direction::Minimize),
std::cmp::Ordering::Greater
);
}
#[test]
fn compare_so_two_feasible_under_min_and_max() {
let a = Evaluation::new(vec![1.0]);
let b = Evaluation::new(vec![2.0]);
assert_eq!(compare_so(&a, &b, Direction::Minimize), std::cmp::Ordering::Less);
assert_eq!(compare_so(&b, &a, Direction::Minimize), std::cmp::Ordering::Greater);
assert_eq!(
compare_so(&a, &b, Direction::Minimize),
std::cmp::Ordering::Less
);
assert_eq!(
compare_so(&b, &a, Direction::Minimize),
std::cmp::Ordering::Greater
);
// Maximize inverts.
assert_eq!(compare_so(&a, &b, Direction::Maximize), std::cmp::Ordering::Greater);
assert_eq!(compare_so(&b, &a, Direction::Maximize), std::cmp::Ordering::Less);
assert_eq!(
compare_so(&a, &b, Direction::Maximize),
std::cmp::Ordering::Greater
);
assert_eq!(
compare_so(&b, &a, Direction::Maximize),
std::cmp::Ordering::Less
);
}
#[test]
@@ -787,8 +805,14 @@ mod tests {
a.constraint_violation = 0.5;
let mut b = Evaluation::new(vec![0.0]);
b.constraint_violation = 1.0;
assert_eq!(compare_so(&a, &b, Direction::Minimize), std::cmp::Ordering::Less);
assert_eq!(compare_so(&b, &a, Direction::Minimize), std::cmp::Ordering::Greater);
assert_eq!(
compare_so(&a, &b, Direction::Minimize),
std::cmp::Ordering::Less
);
assert_eq!(
compare_so(&b, &a, Direction::Minimize),
std::cmp::Ordering::Greater
);
}
#[test]