Code Review
/
yardstick.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Convert SLA asserts to raises
[yardstick.git]
/
yardstick
/
benchmark
/
runners
/
dynamictp.py
diff --git
a/yardstick/benchmark/runners/dynamictp.py
b/yardstick/benchmark/runners/dynamictp.py
index
63bfc82
..
88d3c57
100755
(executable)
--- a/
yardstick/benchmark/runners/dynamictp.py
+++ b/
yardstick/benchmark/runners/dynamictp.py
@@
-27,6
+27,7
@@
import traceback
import os
from yardstick.benchmark.runners import base
import os
from yardstick.benchmark.runners import base
+from yardstick.common import exceptions as y_exc
LOG = logging.getLogger(__name__)
LOG = logging.getLogger(__name__)
@@
-80,10
+81,10
@@
def _worker_process(queue, cls, method_name, scenario_cfg,
try:
method(data)
try:
method(data)
- except
AssertionError as assertion
:
- LOG.warning("SLA validation failed: %s"
% assertion
.args)
+ except
y_exc.SLAValidationError as error
:
+ LOG.warning("SLA validation failed: %s"
, error
.args)
too_high = True
too_high = True
- except Exception as e:
+ except Exception as e:
# pylint: disable=broad-except
errors = traceback.format_exc()
LOG.exception(e)
errors = traceback.format_exc()
LOG.exception(e)