summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorClark Williams <williams@redhat.com>2012-03-26 13:25:51 -0500
committerClark Williams <williams@redhat.com>2012-03-26 13:25:51 -0500
commitc9870e6cbad0fbd8689e8b91b06e01c2f971bd82 (patch)
treeea28f36e460dc050507b2b514c297dd61e110a46
parent95f284274540252a8ca6b1c58816f82aa956c0d0 (diff)
downloadrt-tests-c9870e6cbad0fbd8689e8b91b06e01c2f971bd82.tar.gz
report number of samples written in hwlatdetect
Signed-off-by: Clark Williams <williams@redhat.com>
-rwxr-xr-xsrc/hwlatdetect/hwlatdetect.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/hwlatdetect/hwlatdetect.py b/src/hwlatdetect/hwlatdetect.py
index 66e66a2..ca47c1c 100755
--- a/src/hwlatdetect/hwlatdetect.py
+++ b/src/hwlatdetect/hwlatdetect.py
@@ -519,11 +519,13 @@ if __name__ == '__main__':
info("Samples exceeding threshold: %d" % exceeding)
if reportfile:
+ count = 0
f = open(reportfile, "w")
for s in detect.samples:
+ count += 1
f.write("%s\n" % s)
f.close()
- info("sample data written to %s" % reportfile)
+ info("sample data (%d samples) written to %s" % (count, reportfile))
else:
for s in detect.samples:
print "%s" % s