Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r81657 - trunk/tools/regression/src
From: ramey_at_[hidden]
Date: 2012-12-01 17:13:54


Author: ramey
Date: 2012-12-01 17:13:53 EST (Sat, 01 Dec 2012)
New Revision: 81657
URL: http://svn.boost.org/trac/boost/changeset/81657

Log:
fixed error
Text files modified:
   trunk/tools/regression/src/library_status.cpp | 43 +++++++++++++--------------------------
   1 files changed, 14 insertions(+), 29 deletions(-)

Modified: trunk/tools/regression/src/library_status.cpp
==============================================================================
--- trunk/tools/regression/src/library_status.cpp (original)
+++ trunk/tools/regression/src/library_status.cpp 2012-12-01 17:13:53 EST (Sat, 01 Dec 2012)
@@ -1,6 +1,5 @@
 // Generate Library Status HTML from jam regression test output -----------//
 
-//..Copyright Robert Ramey 2012
 // Copyright Bryce Lelbach 2011
 // Copyright Beman Dawes 2002-2011.
 
@@ -389,8 +388,6 @@
             return true;
         }
 
- int anything_generated = 0;
-
 
         string test_type( "unknown" );
         bool always_show_run_output( false );
@@ -402,33 +399,21 @@
         always_show_run_output
             = attribute_value( db, "show-run-output" ) == "true";
 
- /*
- test_type = attribute_value( db, "test-type" );
- std::string test_type_base( test_type );
- if ( test_type_base.size() > 5 )
- {
- const string::size_type trailer = test_type_base.size() - 5;
- if ( test_type_base.substr( trailer ) == "_fail" )
- {
- test_type_base.erase( trailer );
+ // if we don't find any failures
+ // mark it as a pass
+ struct predicate {
+ //bool operator()(const boost::shared_ptr<const xml::element> e) const {
+ bool operator()(const xml::element_ptr & e) const {
+ return attribute_value(*e, "result") == "fail";
             }
- }
- if ( test_type_base.size() > 4 )
- {
- const string::size_type trailer = test_type_base.size() - 4;
- if ( test_type_base.substr( trailer ) == "_pyd" )
- {
- test_type_base.erase( trailer );
- }
- }
-
- xml::element_list::const_iterator itr;
- itr = find_element( db, test_type_base );
- if(db.elements.end() == itr)
- return pass;
- */
- pass = (attribute_value( db, "result" ) != "fail");
+ };
+ pass = (db.elements.end() == std::find_if(
+ db.elements.begin(),
+ db.elements.end(),
+ predicate()
+ ));
 
+ int anything_generated = 0;
         if (!no_links){
             anything_generated =
                 generate_report(
@@ -483,7 +468,7 @@
     ){
         bool retval = false;
         if(node.is_leaf){
- retval = do_cell(
+ return do_cell(
                 dir_root,
                 lib_name,
                 test_name,


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