aboutsummaryrefslogtreecommitdiff
path: root/bench_mysql.py
diff options
context:
space:
mode:
authorFlorian Fischer <florian.fl.fischer@fau.de>2018-07-21 20:24:06 +0200
committerFlorian Fischer <florian.fl.fischer@fau.de>2018-07-21 20:24:06 +0200
commit56c8444a05773b5158fce4dbbc88366ba2da35e8 (patch)
treecc92cc3d218b1cfef1fa04e4d889bd521d14dff0 /bench_mysql.py
parentf260cf2b7dd5ec34fcd51691dea7aad0576e8ab9 (diff)
downloadallocbench-56c8444a05773b5158fce4dbbc88366ba2da35e8.tar.gz
allocbench-56c8444a05773b5158fce4dbbc88366ba2da35e8.zip
check returncode of prepare cmd
Diffstat (limited to 'bench_mysql.py')
-rw-r--r--bench_mysql.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/bench_mysql.py b/bench_mysql.py
index d903c2e..b8bec25 100644
--- a/bench_mysql.py
+++ b/bench_mysql.py
@@ -92,10 +92,11 @@ class Benchmark_MYSQL( Benchmark ):
return ret
print("Prepare test table")
- subprocess.run(prepare_cmd)
+ p = subprocess.run(prepare_cmd)
+ ret = ret == p.returncode == 0
self.server.kill()
ret = ret and self.server.wait() == -9
-
+
return ret
def cleanup(self):
@@ -103,7 +104,6 @@ class Benchmark_MYSQL( Benchmark ):
print("Delete mysqld directory")
shutil.rmtree("mysql_test")
-
def run(self, verbose=False, save=False, runs=3):
cwd = os.getcwd()
for run in range(1, runs + 1):