diff --git a/tr-examples/configuration.tplan2.tdltx b/tr-examples/configuration.tplan2.tdltx new file mode 100644 index 0000000000000000000000000000000000000000..86fa3c1082032647def274cd3cbdab4664813f45 --- /dev/null +++ b/tr-examples/configuration.tplan2.tdltx @@ -0,0 +1,15 @@ +Package base_configuration { + Import all from data + Annotation Final conditions + Annotation Expected behaviour + Annotation Initial conditions + Message Gate wireless accepts position + Component unit { + gate wireless wifi + } + Configuration basic { + unit controller as Tester, + unit object as SUT, + connect controller::wifi to object::wifi + } +} \ No newline at end of file diff --git a/tr-examples/data.tplan2.tdltx b/tr-examples/data.tplan2.tdltx new file mode 100644 index 0000000000000000000000000000000000000000..00739be50ae7177dd3e64df770ed9fc383d72485 --- /dev/null +++ b/tr-examples/data.tplan2.tdltx @@ -0,0 +1,16 @@ +Package data { + Annotation Final conditions + Annotation Expected behaviour + Annotation Initial conditions + Type float + Structure position ( + float x, + float y + ) + float _22 + float _21 + position startingPosition ( + Note : "indicating value" + x = instance _21 + ) +} \ No newline at end of file diff --git a/tr-examples/data_tables.tdlan2.tdltx b/tr-examples/data_tables.tdlan2.tdltx new file mode 100644 index 0000000000000000000000000000000000000000..c3a73a040a14cd53daf53f75ad9f8c2f3fcded69 --- /dev/null +++ b/tr-examples/data_tables.tdlan2.tdltx @@ -0,0 +1,20 @@ +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 ( inferred_position position ) + Test Description TC_MOVE_TO ( + inferred_position target_position ) uses inferred_move_object { + Controller::inferred_gate sends parameter target_position to Object::inferred_gate + perform move_to ( position = parameter target_position ) on Object + } + Test Description TC_MOVE_AROUND uses inferred_move_object { + execute TC_MOVE_TO ( target_position = instance start_position ) + execute TC_MOVE_TO ( target_position = instance open_position ) + execute TC_MOVE_TO ( target_position = instance closed_position ) + execute TC_MOVE_TO ( target_position = instance end_position ) + } +} \ No newline at end of file diff --git a/tr-examples/descriptions.tdlan2.tdltx b/tr-examples/descriptions.tdlan2.tdltx new file mode 100644 index 0000000000000000000000000000000000000000..b8b8877c55df1345d6a3c1008fc7ae1f396f6d0c --- /dev/null +++ b/tr-examples/descriptions.tdlan2.tdltx @@ -0,0 +1,33 @@ +/* +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. +*/ + +//Inferred (manually) from objectives.tplan2 +Package descriptions { + Import all from inferred_configuration + Import all from inferred_data + + Action move_to ( inferred_position position) + + Test Description TD_MOVE_OBJECT_LITERAL uses inferred_move_object { + Controller::inferred_gate sends inferred_start_position to Object::inferred_gate + perform move_to ( position = inferred_start_position ) on Object + } + + Test Description TD_MOVE_OBJECT_LITERAL_INLINE uses inferred_move_object { + Controller::inferred_gate sends new inferred_position (x = 22, y = 21) to Object::inferred_gate + perform 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.tdltx b/tr-examples/domain.tplan2.tdltx new file mode 100644 index 0000000000000000000000000000000000000000..942a81cf13f539faf7f7156b9efd4c013aaf50f8 --- /dev/null +++ b/tr-examples/domain.tplan2.tdltx @@ -0,0 +1,12 @@ +Package domain { + Annotation Final conditions + Annotation Expected behaviour + Annotation Initial conditions + PICS MOVABLE + Entity Object + Entity Controller + Event sends + Event receives + Event moves + Event moves_to +} \ No newline at end of file diff --git a/tr-examples/inferred_configuration.tdlan2.tdltx b/tr-examples/inferred_configuration.tdlan2.tdltx new file mode 100644 index 0000000000000000000000000000000000000000..13943ea83ebb795cdc7fbd503f9439b28ed92e10 --- /dev/null +++ b/tr-examples/inferred_configuration.tdlan2.tdltx @@ -0,0 +1,12 @@ +Package inferred_configuration { + Import all from data + Message Gate inferred_gate_type accepts position + Component inferred_component_type { + gate inferred_gate_type inferred_gate + } + Configuration inferred_move_object { + inferred_component_type Controller as Tester, + inferred_component_type Object as SUT, + connect Controller::inferred_gate to Object::inferred_gate + } +} \ No newline at end of file diff --git a/tr-examples/inferred_data.tdlan2.tdltx b/tr-examples/inferred_data.tdlan2.tdltx new file mode 100644 index 0000000000000000000000000000000000000000..573c27f5384f6ecc1f2b864c1d1cbdbeb8fc2116 --- /dev/null +++ b/tr-examples/inferred_data.tdlan2.tdltx @@ -0,0 +1,23 @@ +/* +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. +*/ + +//Inferred (manually) from objectives.tplan2 +Package inferred_data { + Type inferred_simple + Structure inferred_position ( inferred_simple x, inferred_simple y ) + inferred_simple _22 + inferred_simple _21 + inferred_position inferred_start_position ( x = 22, y = 21 ) +} diff --git a/tr-examples/objectives.tplan2.tdltx b/tr-examples/objectives.tplan2.tdltx new file mode 100644 index 0000000000000000000000000000000000000000..7e4af0f69d16933422f38f5a032995413d61a7eb --- /dev/null +++ b/tr-examples/objectives.tplan2.tdltx @@ -0,0 +1,87 @@ +/* +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. +*/ + +//Structured test objective specifications +Package objectives { + Import all from Standard + Import all from data + Import all from domain + Import all from base_configuration + Test Purpose TP_MOVE_OBJECT_LITERAL { + Objective: "Move object to destination with literal values." + PICS: 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_MOVE_OBJECT_PREDEFINED { + Objective: "Move object to destination with predefined values." + Expected behaviour + ensure that { + when { + the Controller entity sends the (predefined) instance startingPosition ( x = 21, y = 21) + } then { + the Object entity moves_to the (predefined) instance startingPosition + } + } + } + +// Test Purpose TP_MOVE_OBJECT_TYPED { +// 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 +// } +// } +// } + +Objective TO_MOVE_OBJECT_UNIFIED { + Description: "Move object to destination with unified test purpose description." +} + +Test Purpose Description TP_MOVE_OBJECT_UNIFIED ( position startingPosition ) { + Objective: TO_MOVE_OBJECT_UNIFIED + Configuration: basic + Expected behaviour + ensure that { + when { + perform action: "the Controller sends the starting position" + controller::wifi sends "x=21, y=21" to object::wifi + controller::wifi sends position (x = 21, y = 21) to object::wifi + } then { + perform action: "the Object moves to the requested position" + controller::wifi receives "x=21, y=21" from object::wifi + controller::wifi receives position (x = 21, y = 21) from object::wifi + } + } +} + + +} \ No newline at end of file diff --git a/tr-examples/objectives.tplan2.tdltx.tdltx b/tr-examples/objectives.tplan2.tdltx.tdltx new file mode 100644 index 0000000000000000000000000000000000000000..e164d0fba76225e26a933ac9a184bab181f96e58 --- /dev/null +++ b/tr-examples/objectives.tplan2.tdltx.tdltx @@ -0,0 +1,64 @@ +Package objectives { + Import all from Standard + Import all from data + Import all from domain + Import all from base_configuration + Test Purpose TP_MOVE_OBJECT_LITERAL { + Objective: "Move object to destination with literal values." + PICS: 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_MOVE_OBJECT_PREDEFINED { + Objective: "Move object to destination with predefined values." + Expected behaviour + ensure that { + when { + the Controller entity sends + the + (predefined) instance startingPosition ( + x = 21, + y = 21 + ) + } then { + the Object entity moves_to + the + (predefined) instance startingPosition + } } + } + Objective TO_MOVE_OBJECT_UNIFIED { + Description: "Move object to destination with unified test purpose description." + } + Objective: TO_MOVE_OBJECT_UNIFIED + @Test Purpose Description + Test Description TP_MOVE_OBJECT_UNIFIED uses basic { + @Expected behaviour + { + @when + { + perform action : "the Controller sends the starting position" + controller::wifi sends "x=21, y=21" to object::wifi + controller::wifi sends position ( + x = 21, + y = 21 + ) to object::wifi + } + @then + { + perform action : "the Object moves to the requested position" + object::wifi sends "x=21, y=21" to controller::wifi + object::wifi sends position ( + x = 21, + y = 21 + ) to controller::wifi + } + } + } +} \ No newline at end of file diff --git a/tr-examples/objectives.tplan2.tdltx.tdltx.docx b/tr-examples/objectives.tplan2.tdltx.tdltx.docx new file mode 100644 index 0000000000000000000000000000000000000000..2c137850432dc87fb54ce1063e8cb7bab6f6798c Binary files /dev/null and b/tr-examples/objectives.tplan2.tdltx.tdltx.docx differ