Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.toolbox
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Klaus Wölfel
slapos.toolbox
Commits
ed7f5603
Commit
ed7f5603
authored
Sep 25, 2018
by
Guillaume Hervier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
resiliencytest: Fix exception reporting in runTestSuite function.
/reviewed-on
nexedi/slapos.toolbox!37
parent
f873f59d
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
4 deletions
+3
-4
slapos/resiliencytest/__init__.py
slapos/resiliencytest/__init__.py
+3
-4
No files found.
slapos/resiliencytest/__init__.py
View file @
ed7f5603
...
@@ -109,7 +109,7 @@ def setupLogging(name=__name__, log_path=None):
...
@@ -109,7 +109,7 @@ def setupLogging(name=__name__, log_path=None):
logger
=
logging
.
getLogger
(
name
)
logger
=
logging
.
getLogger
(
name
)
return
logger
,
fname
return
logger
,
fname
def
runTestSuite
(
test_suite_title
,
test_suite_arguments
,
log
):
def
runTestSuite
(
test_suite_title
,
test_suite_arguments
,
log
ger
):
"""
"""
Run a specified test suite, by dynamically loading the module and calling
Run a specified test suite, by dynamically loading the module and calling
its "runTestSuite" method.
its "runTestSuite" method.
...
@@ -121,8 +121,7 @@ def runTestSuite(test_suite_title, test_suite_arguments, log):
...
@@ -121,8 +121,7 @@ def runTestSuite(test_suite_title, test_suite_arguments, log):
test_suite_module
=
importFrom
(
test_suite_title
)
test_suite_module
=
importFrom
(
test_suite_title
)
success
=
test_suite_module
.
runTestSuite
(
**
parsed_arguments
)
success
=
test_suite_module
.
runTestSuite
(
**
parsed_arguments
)
except
:
except
:
log
(
'Impossible to run resiliency test:'
)
logger
.
exception
(
'Impossible to run resiliency test:'
)
log
(
traceback
.
print_exc
())
success
=
False
success
=
False
return
success
return
success
...
@@ -259,7 +258,7 @@ def runUnitTest():
...
@@ -259,7 +258,7 @@ def runUnitTest():
success
=
runTestSuite
(
success
=
runTestSuite
(
args
.
test_suite
,
args
.
test_suite
,
args
.
additional_arguments
,
args
.
additional_arguments
,
logger
.
info
,
logger
,
)
)
if
success
:
if
success
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment