Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
AIG-public
Cobalt
Commits
490d21b3
Commit
490d21b3
authored
Mar 05, 2018
by
Paul Rich
Browse files
Fixing exception propigation so that the mock is closer to what cray_messaging does.
parent
140fe35a
Changes
1
Hide whitespace changes
Inline
Side-by-side
testsuite/TestCobalt/TestComponents/test_cray.py
View file @
490d21b3
...
...
@@ -16,7 +16,11 @@ from mock import MagicMock, Mock, patch
# need to mock the import of a dependency library for sending messages to BASIL.
# None of these tests actually communicate with BASIL and this library should be a stub
# for these purposes
sys
.
modules
[
'Cobalt.Components.system.CraySystem.cray_messaging'
]
=
MagicMock
()
cray_messaging_mock
=
MagicMock
()
# This error gets passed through the ALPSBridge module as ALPSError, but originates from
# cray_messaging.
cray_messaging_mock
.
ALPSError
=
ValueError
sys
.
modules
[
'cray_messaging'
]
=
cray_messaging_mock
from
nose.tools
import
raises
from
testsuite.TestCobalt.Utilities.assert_functions
import
assert_match
,
assert_not_match
...
...
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