1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

tests: runner updates line with last timestamp

This commit is contained in:
Zdenek Kabelac 2024-05-08 16:02:44 +02:00
parent a3dcdf5671
commit 7a74229a8e

View File

@ -955,6 +955,11 @@ struct TestCase {
child.interactive = options.interactive;
}
void show_progress() {
progress( Update ) << tag( "running" )
<< pretty() << " " << start.elapsed() << std::flush;
}
bool monitor() {
/* heartbeat */
if ( last_heartbeat.elapsed().sec() >= 20 && !options.heartbeat.empty() ) {
@ -968,6 +973,7 @@ struct TestCase {
if ( wait4(pid, &status, WNOHANG, &usage) != 0 ) {
io.sync( true );
show_progress();
return false;
}
@ -1001,8 +1007,7 @@ struct TestCase {
if ( !options.verbose && !options.interactive && !options.batch ) {
if ( last_update.elapsed().sec() ) {
progress( Update ) << tag( "running" )
<< pretty() << " " << start.elapsed() << std::flush;
show_progress();
last_update.gettime();
}
}