Skip to content

Commit 84c7cb1

Browse files
committed
Do not assume the default solver handles binary variables
1 parent a642f97 commit 84c7cb1

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

tests/solver_scaling.rs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,5 @@ fn sum_binaries() {
3636
let mut vars = variables!();
3737
let team1_bools = vars.add_vector(variable().binary(), BIG_NUM);
3838
let team1_score: Expression = team1_bools.iter().sum();
39-
let sol = vars
40-
.maximise(team1_bools[0])
41-
.using(default_solver)
42-
.with(constraint!(team1_score == 5))
43-
.solve()
44-
.unwrap();
45-
assert_eq!(team1_bools.iter().map(|&v| sol.value(v)).sum::<f64>(), 5.0);
39+
let _constraint = constraint!(team1_score == 5);
4640
}

0 commit comments

Comments
 (0)