Skip to content

Fix #773: Add bf_vs_ilp tests for all ILP reduction rules#778

Merged
GiggleLiu merged 5 commits intomainfrom
add-bf-vs-ilp-tests
Mar 28, 2026
Merged

Fix #773: Add bf_vs_ilp tests for all ILP reduction rules#778
GiggleLiu merged 5 commits intomainfrom
add-bf-vs-ilp-tests

Conversation

@isPANN
Copy link
Copy Markdown
Collaborator

@isPANN isPANN commented Mar 26, 2026

Summary

  • Add test_*_to_ilp_bf_vs_ilp tests for all 85 ILP reduction rules (46 were missing)
  • Extract shared assert_bf_vs_ilp helper in test_helpers.rs to eliminate boilerplate
  • Remove duplicate BF-vs-ILP comparisons from MVC/MIS closed_loop tests (now owned by bf_vs_ilp)
  • Delete fully redundant OLA optimization test subsumed by bf_vs_ilp

Test plan

  • cargo test --features ilp bf_vs_ilp — 85 passed
  • make check — fmt, clippy, full test suite all green
  • Zero compiler warnings

Closes #773

🤖 Generated with Claude Code

isPANN and others added 4 commits March 26, 2026 22:25
Every *_ilp.rs test file now has a test_*_to_ilp_bf_vs_ilp function
that solves the source problem with BruteForce, solves the ILP
reduction with ILPSolver, extracts the solution back, and asserts
the two objective values match.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Extract shared `assert_bf_vs_ilp` helper into `test_helpers.rs` and
refactor 44 bf_vs_ilp tests to use it, eliminating ~216 lines of
duplicated solve-compare boilerplate. Clean up unused Solver imports.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The bf_vs_ilp tests now own the BF-vs-ILP value comparison.
Simplify MVC/MIS closed_loop tests to only assert structural
properties (ilp_size, is_valid). Delete OLA optimization test
that was fully subsumed by bf_vs_ilp.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@codecov
Copy link
Copy Markdown

codecov bot commented Mar 26, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.86%. Comparing base (f29cfb1) to head (bc7bb99).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff            @@
##             main     #778    +/-   ##
========================================
  Coverage   97.85%   97.86%            
========================================
  Files         625      625            
  Lines       68311    68578   +267     
========================================
+ Hits        66846    67113   +267     
  Misses       1465     1465            

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@GiggleLiu GiggleLiu merged commit 4bed271 into main Mar 28, 2026
5 checks passed
@GiggleLiu GiggleLiu deleted the add-bf-vs-ilp-tests branch April 12, 2026 00:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add bf_vs_ilp tests for all ILP reduction rules

2 participants