Ignore:
Timestamp:
Aug 13, 2010, 7:30:03 PM (11 years ago)
Author:
Peter Johansson
Message:

new function exit_status in Suite and use it in all C++ tests

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/stats_test.cc

    r1124 r1162  
    6262
    6363  bool verbose=suite.verbose();
    64   bool ok=true;
    6564
    6665  SVN* svn=SVN::instance("toy_project");
     
    7069  }
    7170
    72   ok &= test_add(suite);
    73   ok &= test_blame(suite);
    74   ok &= test_classic(suite);
     71  suite.add(test_add(suite));
     72  suite.add(test_blame(suite));
     73  suite.add(test_classic(suite));
    7574                                                                               
    76   if (verbose) {
    77     if (ok)
    78       std::cout << "Test is ok.\n";
    79     else
    80       std::cout << "Test failed.\n";
    81   }
    82   if (ok)
    83     return 0;
    84   return 1;
     75  return suite.exit_status();
    8576}
    8677
Note: See TracChangeset for help on using the changeset viewer.