From: Markus Lehtonen Date: Mon, 5 Sep 2016 18:33:56 +0000 (+0300) Subject: oeqa.buildperf: correct globalres time format X-Git-Tag: lucaceresoli/bug-15201-perf-libtraceevent-missing~24369 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=55bb6816aca39bfa25d4f7e2158a57a5f0ac1cca;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git oeqa.buildperf: correct globalres time format Always use two digits for (integer part of) seconds, i.e. show '1:02.34' instead of '1:2.34'. Signed-off-by: Markus Lehtonen Signed-off-by: Richard Purdie --- diff --git a/meta/lib/oeqa/buildperf/base.py b/meta/lib/oeqa/buildperf/base.py index be3a946ddf2..2325cd1d6be 100644 --- a/meta/lib/oeqa/buildperf/base.py +++ b/meta/lib/oeqa/buildperf/base.py @@ -404,7 +404,7 @@ class BuildPerfTestCase(unittest.TestCase): # Append to 'times' array for globalres log e_sec = etime.total_seconds() - self.times.append('{:d}:{:02d}:{:.2f}'.format(int(e_sec / 3600), + self.times.append('{:d}:{:02d}:{:05.2f}'.format(int(e_sec / 3600), int((e_sec % 3600) / 60), e_sec % 60))