Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r55257 - trunk/libs/graph/test
From: jewillco_at_[hidden]
Date: 2009-07-30 14:44:40


Author: jewillco
Date: 2009-07-29 08:49:27 EDT (Wed, 29 Jul 2009)
New Revision: 55257
URL: http://svn.boost.org/trac/boost/changeset/55257

Log:
Used filename from argument list rather than hard-coded name to fix regression test problems
Text files modified:
   trunk/libs/graph/test/cycle_ratio_tests.cpp | 3 ++-
   1 files changed, 2 insertions(+), 1 deletions(-)

Modified: trunk/libs/graph/test/cycle_ratio_tests.cpp
==============================================================================
--- trunk/libs/graph/test/cycle_ratio_tests.cpp (original)
+++ trunk/libs/graph/test/cycle_ratio_tests.cpp 2009-07-29 08:49:27 EDT (Wed, 29 Jul 2009)
@@ -213,6 +213,7 @@
 
 int test_main(int argc, char* argv[])
 {
+ assert (argc >= 2);
   using std::endl; using std::cout;
   const double epsilon = 0.005;
   double min_cr, max_cr; ///Minimum and maximum cycle ratio
@@ -291,7 +292,7 @@
   }
 
   {
- read_data("cycle_ratio_s382.90.dot", tg);
+ read_data(argv[1], tg);
       min_cr = boost::minimum_cycle_ratio(tg, vim, ew1m, ew2m, &cc, my_float2());
       cout << "Minimum cycle ratio is " << min_cr << endl;
       BOOST_CHECK(std::abs(min_cr - 0.33333333333) < epsilon );


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk