diff --git a/tr-examples/configuration.tplan2 b/tr-examples/configuration.tplan2 new file mode 100644 index 0000000000000000000000000000000000000000..4181b835ba3adc226467bd83179bd1336e27e5a1 --- /dev/null +++ b/tr-examples/configuration.tplan2 @@ -0,0 +1,12 @@ +Package base_configuration { + import all from data; + Configuration { + Interface Type wireless accepts position; + Component Type unit with gate wifi of type wireless; + Test Configuration basic containing + Tester component controller of type unit + SUT component object of type unit + connection between controller.wifi and object.wifi + ; + } +} \ No newline at end of file diff --git a/tr-examples/configuration.tplan2.tdl b/tr-examples/configuration.tplan2.tdl new file mode 100644 index 0000000000000000000000000000000000000000..7d9486db77d4ce5f529acff746c1f89bf787ea72 --- /dev/null +++ b/tr-examples/configuration.tplan2.tdl @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/tr-examples/configuration.tplan2.tdl.tdlan2 b/tr-examples/configuration.tplan2.tdl.tdlan2 new file mode 100644 index 0000000000000000000000000000000000000000..a98be4c001120b8227c21b607fc0d7f22b7c098b --- /dev/null +++ b/tr-examples/configuration.tplan2.tdl.tdlan2 @@ -0,0 +1,12 @@ +Package base_configuration { + Import all from data ; + Gate Type wireless accepts position ; + Component Type unit having { + gate wifi of type wireless ; + } + Test Configuration basic { + create Tester controller of type unit ; + create SUT object of type unit ; + connect controller.wifi to object.wifi ; + } +} \ No newline at end of file diff --git a/tr-examples/data.tplan2 b/tr-examples/data.tplan2 new file mode 100644 index 0000000000000000000000000000000000000000..94d427dfe55781ad8e0cfafda9bfa2fd5f68cd51 --- /dev/null +++ b/tr-examples/data.tplan2 @@ -0,0 +1,9 @@ +Package data { + Data { + type float; + type position with x of type float, y of type float; + float -22; + float -21; + position startingPosition containing x indicating value -21; + } +} \ No newline at end of file diff --git a/tr-examples/data.tplan2.tdl b/tr-examples/data.tplan2.tdl new file mode 100644 index 0000000000000000000000000000000000000000..a65a259f9e6832a0fdce84c32af321e5f8d5d12f --- /dev/null +++ b/tr-examples/data.tplan2.tdl @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/tr-examples/data.tplan2.tdl.tdlan2 b/tr-examples/data.tplan2.tdl.tdlan2 new file mode 100644 index 0000000000000000000000000000000000000000..ea2f2c40b954bf61cfafc6832c1f5a992b752cea --- /dev/null +++ b/tr-examples/data.tplan2.tdl.tdlan2 @@ -0,0 +1,25 @@ +/* +Copyright (c) ETSI 2020. + +This software is subject to copyrights owned by ETSI. Non-exclusive permission +is hereby granted, free of charge, to copy, reproduce and amend this file +under the following conditions: It is provided "as is", without warranty of any +kind, expressed or implied. + +ETSI shall never be liable for any claim, damages, or other liability arising +from its use or inability of use.This permission does not apply to any documentation +associated with this file for which ETSI keeps all rights reserved. The present +copyright notice shall be included in all copies of whole or part of this +file and shall not imply any sub-license right. +*/ + +//Converted from data.tplan2 - same model, different representation +Package tdl_data { + Type integer ; + Type string ; + Type float ; + Type position ( x of type float , y of type float ) ; + position startingPosition ( x = -21 ) ; + float -22 ; + float -21 ; +} \ No newline at end of file diff --git a/tr-examples/data_tables.tdlan2 b/tr-examples/data_tables.tdlan2 new file mode 100644 index 0000000000000000000000000000000000000000..4f942469c2d0c1026c1b7f187a4e13a84a3f02aa --- /dev/null +++ b/tr-examples/data_tables.tdlan2 @@ -0,0 +1,25 @@ +Package data_tables { + Import all from inferred_data; + Import all from inferred_configuration; + + inferred_position start_position(); + inferred_position open_position(); + inferred_position closed_position(); + inferred_position end_position(); + + Action move_to (position of type inferred_position); + + Test Description TC_MOVE_TO ( + target_position of type inferred_position + ) uses configuration inferred_move_object { + Controller.inferred_gate sends parameter target_position to Object.inferred_gate; + perform action move_to (position = parameter target_position) on Object; + } + + Test Description TC_MOVE_AROUND uses configuration inferred_move_object { + execute TC_MOVE_TO (target_position = start_position); + execute TC_MOVE_TO (target_position = open_position); + execute TC_MOVE_TO (target_position = closed_position); + execute TC_MOVE_TO (target_position = end_position); + } +} \ No newline at end of file diff --git a/tr-examples/descriptions.tdlan2 b/tr-examples/descriptions.tdlan2 new file mode 100644 index 0000000000000000000000000000000000000000..ff3f10b34dd2354424eea006802d2e78cdb2ebe2 --- /dev/null +++ b/tr-examples/descriptions.tdlan2 @@ -0,0 +1,17 @@ +Package descriptions { + Import all from inferred_configuration; + Import all from inferred_data; + + Action move_to (position of type inferred_position); + + Test Description TD_MOVE_OBJECT_LITERAL uses configuration inferred_move_object { + Controller.inferred_gate sends inferred_start_position to Object.inferred_gate; + perform action move_to (position = inferred_start_position) on Object; + } + + Test Description TD_MOVE_OBJECT_LITERAL_INLINE uses configuration inferred_move_object { + Controller.inferred_gate sends new inferred_position (x = 22, y = 21) to Object.inferred_gate; + perform action move_to (position = new inferred_position (x = 22, y = 21)) on Object; + } + +} \ No newline at end of file diff --git a/tr-examples/domain.tplan2 b/tr-examples/domain.tplan2 new file mode 100644 index 0000000000000000000000000000000000000000..d09c81fc640733de518f4fb094c920cf10499e1b --- /dev/null +++ b/tr-examples/domain.tplan2 @@ -0,0 +1,17 @@ +Package domain { + Domain { + pics : + - MOVABLE + ; + entities : + - Object + - Controller + ; + events : + - sends + - receives + - moves + - moves_to + ; + } +} \ No newline at end of file diff --git a/tr-examples/inferred_configuration.tdlan2 b/tr-examples/inferred_configuration.tdlan2 new file mode 100644 index 0000000000000000000000000000000000000000..57b63d5c4d23ce7ddcfb7f2238e9d9f882e7e833 --- /dev/null +++ b/tr-examples/inferred_configuration.tdlan2 @@ -0,0 +1,12 @@ +Package inferred_configuration { + Import all from data ; + Gate Type inferred_gate_type accepts position ; + Component Type inferred_component_type having { + gate inferred_gate of type inferred_gate_type ; + } + Test Configuration inferred_move_object { + create Tester Controller of type inferred_component_type ; + create SUT Object of type inferred_component_type ; + connect Controller.inferred_gate to Object.inferred_gate ; + } +} \ No newline at end of file diff --git a/tr-examples/inferred_data.tdlan2 b/tr-examples/inferred_data.tdlan2 new file mode 100644 index 0000000000000000000000000000000000000000..e52b887faef0d172f3608c36e520eac326fcf84e --- /dev/null +++ b/tr-examples/inferred_data.tdlan2 @@ -0,0 +1,7 @@ +Package inferred_data { + Type inferred_simple ; + Type inferred_position ( x of type inferred_simple, y of type inferred_simple) ; + inferred_simple 22 ; + inferred_simple 21 ; + inferred_position inferred_start_position ( x = 22, y = 21 ) ; +} diff --git a/tr-examples/objectives.tplan2 b/tr-examples/objectives.tplan2 new file mode 100644 index 0000000000000000000000000000000000000000..3a62fc777a03023180156c1f4dd3a4b1a2fab947 --- /dev/null +++ b/tr-examples/objectives.tplan2 @@ -0,0 +1,67 @@ +/* +Copyright (c) ETSI 2020. + +This software is subject to copyrights owned by ETSI. Non-exclusive permission +is hereby granted, free of charge, to copy, reproduce and amend this file +under the following conditions: It is provided "as is", without warranty of any +kind, expressed or implied. + +ETSI shall never be liable for any claim, damages, or other liability arising +from its use or inability of use.This permission does not apply to any documentation +associated with this file for which ETSI keeps all rights reserved. The present +copyright notice shall be included in all copies of whole or part of this +file and shall not imply any sub-license right. +*/ + +Package objectives { + import all from domain; + import all from data; + Test Purpose { + TP Id TP_MOVE_OBJECT_LITERAL + Test objective "Move object to destination with literal values." + PICS Selection MOVABLE + Expected behaviour + ensure that { + when { + the Controller entity sends the start position containing + x indicating value 22, + y indicating value 21 + ; + } then { + the Object entity moves_to the received start position + } + } + } + + Test Purpose { + TP Id TP_MOVE_OBJECT_PREDEFINED + Test objective "Move object to destination with predefined values." + Expected behaviour + ensure that { + when { + the Controller entity sends the (predefined) startingPosition containing + x indicating value -22, + y indicating value -21 + ; + } then { + the Object entity moves_to the (predefined) startingPosition + } + } + } + + Test Purpose { + TP Id TP_MOVE_OBJECT_TYPED + Test objective "Move object to destination with typed values." + Expected behaviour + ensure that { + when { + the Controller entity sends the (typed) starting position containing + x indicating value -22, + y indicating value -21 + ; + } then { + the Object entity moves_to the (typed) starting position + } + } + } +} \ No newline at end of file diff --git a/tr-examples/objectives.tplan2.docx b/tr-examples/objectives.tplan2.docx new file mode 100644 index 0000000000000000000000000000000000000000..2352df65865ad477372663175388897cf75f7c30 Binary files /dev/null and b/tr-examples/objectives.tplan2.docx differ