summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortjung2012-02-04 09:39:33 (EST)
committertjung2012-02-04 09:39:33 (EST)
commita1d63928374f6b4d9ee9d18efd9020fe365265bd (patch)
tree5cdccf33ba1aed6f2114d18a61ab438339740815
parent4cf0af1ebfd6c8c9f9122da470dc8e21f721fbfa (diff)
downloadorg.eclipse.etrice-a1d63928374f6b4d9ee9d18efd9020fe365265bd.zip
org.eclipse.etrice-a1d63928374f6b4d9ee9d18efd9020fe365265bd.tar.gz
org.eclipse.etrice-a1d63928374f6b4d9ee9d18efd9020fe365265bd.tar.bz2
[Bug 369669] add test for explicit signature of port.msg() fixed
-rw-r--r--tests/org.eclipse.etrice.integration.tests/model/org.eclipse.etrice.integration.SendingDataByValueTest.room47
1 files changed, 21 insertions, 26 deletions
diff --git a/tests/org.eclipse.etrice.integration.tests/model/org.eclipse.etrice.integration.SendingDataByValueTest.room b/tests/org.eclipse.etrice.integration.tests/model/org.eclipse.etrice.integration.SendingDataByValueTest.room
index ccd65d3..0f57335 100644
--- a/tests/org.eclipse.etrice.integration.tests/model/org.eclipse.etrice.integration.SendingDataByValueTest.room
+++ b/tests/org.eclipse.etrice.integration.tests/model/org.eclipse.etrice.integration.SendingDataByValueTest.room
@@ -27,7 +27,7 @@ RoomModel org.eclipse.etrice.integration.SendingDataByValueTest {
external Port PingPongPort
}
Behavior {
- Operation printData(d: PingPongData): void {
+ Operation printData(d: PingPongData) {
"System.out.printf(\"\\n\");"
"System.out.printf(\"i8Val: %d \\n\",d.getI8Val());"
"System.out.printf(\"i16Val: %d \\n\",d.getI16Val());"
@@ -82,7 +82,7 @@ RoomModel org.eclipse.etrice.integration.SendingDataByValueTest {
Attribute data : PingPongData
}
Behavior {
- Operation printData(d: PingPongData): void {
+ Operation printData(d: PingPongData) {
"System.out.printf(\"MrPing:\\n\");"
"System.out.printf(\"i8Val: %d \\n\",d.getI8Val());"
"System.out.printf(\"i16Val: %d \\n\",d.getI16Val());"
@@ -191,30 +191,25 @@ RoomModel org.eclipse.etrice.integration.SendingDataByValueTest {
cond {
"(p.i32Val==2) && (p.i8Val==46)"
}
- action {
- "// send default values"
- "PingPongPort.ping(data);"
- ""
- "data.setI8Val((byte) 45);"
- "data.setI16Val((short) 34);"
- "data.setI32Val(80);"
- "data.setF32Val((float)3.14);"
- "data.setF64Val(7.12345);"
- "data.setStringVal(\"Hase !\");"
- ""
- "data.getOwnType().setI8Val((byte)10);"
- "data.getOwnType().setI16Val((short)17);"
- "data.getOwnType().setI32Val(4711);"
- "data.getOwnType().setF32Val((float)3.0815);"
- "data.getOwnType().setF64Val(123.45678);"
- "data.getOwnType().setStringVal(\"Deep Hase !\");"
- "int[] intArray = data.getOwnType().getArrayFromInt32();"
- "for (int i=0;i<intArray.length;i++) {intArray[i] = 10+i;}"
- "data.getOwnType().setArrayFromInt32(intArray);"
- ""
- "PingPongPort.ping(data);"
- "crcGen.update(13);"
- }
+ action {
+ "// send default values"
+ "PingPongPort.ping(data);"
+ ""
+ "data.getOwnType().setI8Val((byte)10);"
+ "data.getOwnType().setI16Val((short)17);"
+ "data.getOwnType().setI32Val(4711);"
+ "data.getOwnType().setF32Val((float)3.0815);"
+ "data.getOwnType().setF64Val(123.45678);"
+ "data.getOwnType().setStringVal(\"Deep Hase !\");"
+ "int[] intArray = data.getOwnType().getArrayFromInt32();"
+ "for (int i=0;i<intArray.length;i++) {intArray[i] = 10+i;}"
+ "data.getOwnType().setArrayFromInt32(intArray);"
+ ""
+ "// use convenient function"
+ "PingPongPort.ping((byte)45,(short)34,80,\\\'c\\\',(float)3.14,7.12345,\\\"Hase !\\\",intArray,data.getOwnType());\""
+ ""
+ "crcGen.update(13);"
+ }
}
Transition tr5: state0 -> state1 {
triggers {