File: TestTspSolver.cpp

package info (click to toggle)
highs 1.10.0%2Bds-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 14,728 kB
  • sloc: cpp: 127,429; ansic: 12,439; python: 3,824; f90: 1,104; cs: 960; lisp: 138; makefile: 51; perl: 46; sh: 38
file content (17 lines) | stat: -rw-r--r-- 510 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#include "HCheckConfig.h"
#include "Highs.h"
#include "catch.hpp"

const bool dev_run = false;
const double double_equal_tolerance = 1e-5;

TEST_CASE("tsp-p01", "[highs_test_tsp_solver]") {
  std::string filename;
  filename = std::string(HIGHS_DIR) + "/check/instances/p01.mps";
  const double optimal_obective_value = 263;
  Highs highs;
  if (!dev_run) highs.setOptionValue("output_flag", false);
  highs.readModel(filename);
  highs.run();
  REQUIRE(highs.getObjectiveValue() == optimal_obective_value);
}