From 5f6c52dff03f2dc85d5b26b7f4469bc85a25ee09 Mon Sep 17 00:00:00 2001 From: Florian Fischer Date: Fri, 13 Dec 2019 14:43:54 +0100 Subject: introduce verbosity aware subprocess.run wrapper and use it in benchmarks --- src/benchmarks/raxmlng.py | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) (limited to 'src/benchmarks/raxmlng.py') diff --git a/src/benchmarks/raxmlng.py b/src/benchmarks/raxmlng.py index dd405f5..786b143 100644 --- a/src/benchmarks/raxmlng.py +++ b/src/benchmarks/raxmlng.py @@ -18,13 +18,12 @@ import os import re -import subprocess import sys from urllib.request import urlretrieve from src.artifact import GitArtifact from src.benchmark import Benchmark -from src.util import print_info +from src.util import print_info, run_cmd RUNTIME_RE = re.compile("Elapsed time: (?P(\\d*.\\d*)) seconds") @@ -59,17 +58,8 @@ class BenchmarkRaxmlng(Benchmark): os.makedirs(raxmlng_builddir, exist_ok=True) # building raxml-ng - proc = subprocess.run( - ["cmake", ".."], - cwd=raxmlng_builddir, - # stdout=subprocess.PIPE, stderr=subprocess.PIPE, - universal_newlines=True) - - proc = subprocess.run( - ["make"], - cwd=raxmlng_builddir, - # stdout=subprocess.PIPE, stderr=subprocess.PIPE, - universal_newlines=True) + run_cmd( ["cmake", ".."], cwd=raxmlng_builddir, output_verbosity=2) + run_cmd( ["make"], cwd=raxmlng_builddir, output_verbosity=2) # create symlinks for exe in ["raxml-ng"]: -- cgit v1.2.3