Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
VIGNET Pierre
cadbiom
Commits
93063634
Commit
93063634
authored
Jan 28, 2020
by
VIGNET Pierre
Browse files
[test] Fix command line test: changes in API of get_transitions_from_model_file
parent
cca016e3
Changes
2
Hide whitespace changes
Inline
Side-by-side
command_line/cadbiom_cmd/tools/solutions.py
View file @
93063634
...
...
@@ -277,9 +277,17 @@ def convert_solutions_to_json(sol_steps, transitions, conditions=True):
# Get transitions for the given event
# Structure of transitions:
# {u'h00': [('Ax', 'n1', {u'label': u'h00[]'}),]
LOGGER
.
debug
(
"convert_solutions_to_json:: %s"
,
transitions
)
step_event
=
transitions
[
event
]
step_event
=
transitions
.
get
(
event
,
None
)
if
not
step_event
:
LOGGER
.
error
(
"convert_solutions_to_json:: event not found in the "
"transitions of the model: %s"
,
event
)
LOGGER
.
error
(
"convert_solutions_to_json:: transitions: %s"
,
transitions
)
decomp_event
[
'event'
]
=
"ERROR, no transition"
else
:
# Get list of transitions
...
...
command_line/test/test_mac.py
View file @
93063634
...
...
@@ -191,7 +191,7 @@ def test_convert_solutions_to_json(raw_feed_output, simulate_mac_complete_file):
fd_model_name
=
raw_feed_output
[
0
]
# Get transitions from the model
model_transitions
=
get_transitions_from_model_file
(
fd_model_name
)
model_transitions
,
_
=
get_transitions_from_model_file
(
fd_model_name
)
decomp_solutions
=
convert_solutions_to_json
(
load_solutions
(
simulate_mac_complete_file
),
model_transitions
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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