Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
kazoo
Commits
c39e8568
Commit
c39e8568
authored
Jul 20, 2021
by
Maxime Perrotin
Browse files
Complete test case with MSC both failing and succeeding
parent
ee4a271f
Changes
4
Hide whitespace changes
Inline
Side-by-side
test/Demo_ABB_Opengeode/MSC_ErrorCase.msc
0 → 100644
View file @
c39e8568
mscdocument Untitled_Document /* MSC AND */;
msg Cabin_Command : (Cabin-button);
msg Floor_Command : (Floor-button);
msg Manual_Control : (Lift-control);
msg Start_Controller : (Start-condition);
msg Housekeeping : (Status);
/* CIF MSCDOCUMENT (0, 0) (1585, 1119) */
mscdocument Untitled_Leaf /* MSC LEAF */;
msc Untitled_MSC;
instance user;
out Start_Controller(nb-of-cycle: 1) to TASTE_System;
in Housekeeping({lift {door-open TRUE, door-closed TRUE, floor-detected FALSE, pos-x 69.999632125}, door door-close}) from TASTE_System;
endinstance;
instance TASTE_System;
in Start_Controller(nb-of-cycle: 1) from user;
out Housekeeping({lift {door-open TRUE, door-closed TRUE, floor-detected FALSE, pos-x 69.999632125}, door door-close}) to user;
endinstance;
endmsc;
endmscdocument;
endmscdocument;
test/Demo_ABB_Opengeode/Makefile
View file @
c39e8568
...
...
@@ -13,7 +13,8 @@ c: test-parse-c # Polyorb_HI_C output
cp
lift_model/
*
work/lift_model/SIMULINK/src
make
-C
work
# Test the MSC converter tool and execute the MSC scenario
./regression.sh
./regression_ok.sh
./regression_nok.sh
test-parse-c
:
clean-c
$(KAZOO)
-p
--gw
\
...
...
test/Demo_ABB_Opengeode/regression_nok.sh
0 → 100755
View file @
c39e8568
#!/bin/bash
cp
MSC_ErrorCase.msc work/binaries/user_GUI
cd
work/binaries/user_GUI
taste-msc2py MSC_ErrorCase.msc
../demo &
PID
=
$!
echo
$PID
python3 ./MSC_ErrorCase.py
RET
=
$?
kill
$PID
||
exit
1
if
[
"
$RET
"
!=
"0"
]
then
echo
TEST CASE FAILED AS EXPECTED
exit
0
else
echo
TEST CASE SUCCEEDED BUT THIS IS NOT EXPECTED
exit
1
fi
test/Demo_ABB_Opengeode/regression.sh
→
test/Demo_ABB_Opengeode/regression
_ok
.sh
View file @
c39e8568
...
...
@@ -5,5 +5,14 @@ taste-msc2py MSC_TestCase.msc
../demo &
PID
=
$!
echo
$PID
python3 ./MSC_TestCase.py
||
(
kill
$PID
&&
echo
'TEST CASE FAILED'
&&
exit
1
||
echo
'FAILED killing demo'
)
kill
$PID
python3 ./MSC_TestCase.py
RET
=
$?
kill
$PID
||
exit
1
if
[
"
$RET
"
!=
"0"
]
then
echo
TEST CASE FAILED
exit
1
else
echo
TEST CASE SUCCESS
exit
0
fi
Write
Preview
Supports
Markdown
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