Account for the result of optimization when adding constraints

This commit is contained in:
Chinmay Garde
2015-06-23 18:07:56 -07:00
parent b78b35d723
commit 9beb286180
2 changed files with 2 additions and 5 deletions

View File

@@ -46,9 +46,7 @@ class Solver {
_constraints[constraint] = tag;
_optimizeObjectiveRow(_objective);
return Result.success;
return _optimizeObjectiveRow(_objective);
}
Result removeContraint(Constraint c) {

View File

@@ -282,8 +282,7 @@ void main() {
expect((right >= left) is Constraint, true);
// TODO: Add assertions for this
s << c1 << c2;
expect(s.addConstraint(c1), Result.success);
});
test('constraint_complex', () {