]> sourceware.org Git - lvm2.git/commitdiff
test: Write a results/list at the end of a test run.
authorPetr Rockai <prockai@redhat.com>
Wed, 25 Jun 2014 23:11:19 +0000 (01:11 +0200)
committerPetr Rockai <prockai@redhat.com>
Thu, 5 Feb 2015 12:47:17 +0000 (13:47 +0100)
test/lib/journal.h
test/lib/runner.cpp

index 6d0e2434d34a433e0db847a8137c3b71fdb0c302..d2f028c884ec8b9d638380ecfe1825bcbe488e16 100644 (file)
@@ -62,11 +62,15 @@ struct Journal {
 
        std::string location_tmp, location;
 
-       void sync() {
-               std::ofstream of( location_tmp.c_str() );
+       void write( std::string path ) {
+               std::ofstream of( path.c_str() );
                for ( Status::iterator i = status.begin(); i != status.end(); ++i )
                        of << i->first << " " << i->second << std::endl;
                of.close();
+       }
+
+       void sync() {
+               write( location_tmp );
                rename( location_tmp.c_str(), location.c_str() );
        }
 
index a0f9fbd1ddb119be9f30e0adf6d7cdb641415c56..287b8f9a65b9259fb7bc8c9f2e9a2a9085cdf09d 100644 (file)
@@ -315,6 +315,7 @@ struct Main {
                }
 
                journal.banner();
+               journal.write( options.outdir + "/list" );
                if ( die || fatal_signal )
                        exit( 1 );
        }
This page took 0.046088 seconds and 5 git commands to generate.