Converting iozone test to run_once.
Part of the patch series to make tests using profiling transparently
Signed-off-by: Lucas Meneghel Rodrigues <lucasmr@br.ibm.com>
git-svn-id: http://test.kernel.org/svn/autotest/trunk@2047 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/client/tests/iozone/iozone.py b/client/tests/iozone/iozone.py
index ee656e6..d752d85 100644
--- a/client/tests/iozone/iozone.py
+++ b/client/tests/iozone/iozone.py
@@ -28,29 +28,16 @@
utils.system('make linux')
- def execute(self, dir = None, iterations=1, args = None):
+ def run_once(self, dir = None, args = None):
self.keyval = open(os.path.join(self.resultsdir, 'keyval'), 'w')
if not dir:
dir = self.tmpdir
os.chdir(dir)
if not args:
args = '-a'
- profilers = self.job.profilers
- if not profilers.only():
- for i in range(iterations):
- output = utils.system_output('%s/src/current/iozone %s' %
- (self.srcdir, args))
- self.__format_results(output)
-
- # Do a profiling run if necessary
- if profilers.present():
- profilers.start(self)
- output = utils.system_output('%s/src/current/iozone %s' %
- (self.srcdir, args))
- self.__format_results(output)
- profilers.stop(self)
- profilers.report(self)
-
+ output = utils.system_output('%s/src/current/iozone %s' %
+ (self.srcdir, args))
+ self.__format_results(output)
self.keyval.close()