@@ -509,6 +509,8 @@ TEST_CASE("MIP-infeasible-start", "[highs_test_mip_solver]") {
509509TEST_CASE (" get-integrality" , " [highs_test_mip_solver]" ) {}
510510
511511TEST_CASE (" MIP-bounds" , " [highs_test_mip_solver]" ) {
512+ const std::string test_name = Catch::getResultCapture ().getCurrentTestName ();
513+ const std::string test_mps = test_name + " .mps" ;
512514 // Introduced due to #1325 observing that LI and UI are needed
513515 HighsLp lp;
514516 lp.num_col_ = 6 ;
@@ -536,7 +538,6 @@ TEST_CASE("MIP-bounds", "[highs_test_mip_solver]") {
536538 const double obj0 = highs.getObjectiveValue ();
537539 if (dev_run) printf (" Optimum at first run: %g\n " , obj0);
538540 // now write out to MPS and load again
539- const std::string test_mps = " test.mps" ;
540541 highs.writeModel (test_mps);
541542 highs.readModel (test_mps);
542543 highs.run ();
@@ -549,8 +550,9 @@ TEST_CASE("MIP-bounds", "[highs_test_mip_solver]") {
549550}
550551
551552TEST_CASE (" MIP-get-saved-solutions" , " [highs_test_mip_solver]" ) {
553+ const std::string test_name = Catch::getResultCapture ().getCurrentTestName ();
554+ const std::string solution_file = test_name + " .sol" ;
552555 const std::string model = " flugpl" ;
553- const std::string solution_file = " MipImproving.sol" ;
554556 const std::string model_file =
555557 std::string (HIGHS_DIR) + " /check/instances/" + model + " .mps" ;
556558 Highs highs;
@@ -617,7 +619,8 @@ TEST_CASE("MIP-max-offset-test", "[highs_test_mip_solver]") {
617619}
618620
619621TEST_CASE (" MIP-get-saved-solutions-presolve" , " [highs_test_mip_solver]" ) {
620- const std::string solution_file = " MipImproving.sol" ;
622+ const std::string test_name = Catch::getResultCapture ().getCurrentTestName ();
623+ const std::string solution_file = test_name + " .sol" ;
621624 Highs highs;
622625 highs.setOptionValue (" output_flag" , dev_run);
623626 highs.setOptionValue (" mip_improving_solution_save" , true );
@@ -835,14 +838,13 @@ TEST_CASE("issue-2204", "[highs_test_mip_solver]") {
835838}
836839
837840TEST_CASE (" ZI Round and Shifting Heuristics" , " [highs_test_mip_solver]" ) {
838- std::string model_file =
839- std::string (HIGHS_DIR) + " /check/instances/rgn.mps" ;
841+ std::string model_file = std::string (HIGHS_DIR) + " /check/instances/rgn.mps" ;
840842
841843 Highs highs;
842844 highs.setOptionValue (" output_flag" , dev_run);
843845 // Enable both heuristics
844846 highs.setOptionValue (" mip_heuristic_run_zi_round" , true );
845- highs.setOptionValue (" mip_heuristic_run_shifting" , true );
847+ highs.setOptionValue (" mip_heuristic_run_shifting" , true );
846848 highs.readModel (model_file);
847849 const HighsModelStatus require_model_status = HighsModelStatus::kOptimal ;
848850 const double optimal_objective = 82.19999924 ;
0 commit comments