Presentation is loading. Please wait.

Presentation is loading. Please wait.

TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes1 Hochschule Osnabrück University of Applied Sciences Contact:

Similar presentations


Presentation on theme: "TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes1 Hochschule Osnabrück University of Applied Sciences Contact:"— Presentation transcript:

1 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes1 Hochschule Osnabrück University of Applied Sciences Contact: r.toenjes@hs-osnabrueck.de 1 2 Test-controlled Development of Communication Services Ralf Tönjes 1, Marten Fischer 1, Patrick Wacht 2 University of Applied Science Osnabrück, Germany University of Applied Science Frankfurt, Germany TTCN-3 User Conference 2011 7 – 9 June 2011 - Bled, Slovenia

2 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes2 Hochschule Osnabrück University of Applied Sciences Agenda  Motivation  Architecture  Service Description  Service Behaviour Model  Test Code Generation  Test Execution

3 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes3 Hochschule Osnabrück University of Applied Sciences Motivation  Testing of communication services is becoming increasingly important  growing complexity of logic  short time to market desired  manual testing is time and cost consuming  test automation required  current service creation environments (SCE) do not support test automation Error

4 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes4 Hochschule Osnabrück University of Applied Sciences How can Test Automation be Realised?  Model-Based Testing  Model describes how a system should behave in response to an action (behaviour model)  Supply the action and see if the system responds as expected ModelSystem Abstract tests Executable tests are derived from can be run against are abstract versions of is a partial description of

5 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes5 Hochschule Osnabrück University of Applied Sciences Architecture Step 1 Step 2Step 3 Step 4

6 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes6 Hochschule Osnabrück University of Applied Sciences Step1: Formal Recording of Service Description 5 Stages Procedure  Adopted from telecom software development process OTES (Objects Through Essential Services) 1.Short textual description of use cases 2.Identification of roles of communication participants (e.g. browser, SIP-phone, Database) 3.Requirement specification (including pre- and post-conditions, i.e. states, and target action, i.e. messages sequence, for users) 4.Enhanced requirements specification (including technical details, such as value ranges, names of databases, tables and fields) 5.Identification of the communication interfaces (5-tuple of source and destination IP-address, port and protocol)

7 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes7 Hochschule Osnabrück University of Applied Sciences Example: Click-to-Instant-Message (Click2IM) RequirementClick2InstantMessage_01 Stage 1: Description After request of web site, input of destination address and text required. Inputs will be approved and the text will be transfered to the softphone having the destination address. Receipt of test will then be confirmed. Stage 2: Roles Web Browser SIP Softphone Stage 3: Preconditions Web site accessible Destination address filled in Text filled in Approved inputs TargetSoftphone accessible Postcondition Softphone has received text Confirmation is shown on web site Stage 4:….

8 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes8 Hochschule Osnabrück University of Applied Sciences TTCN-3 requirements: 1.message flow description  derived from FSM (test cases) 2.test environment/SUT description  using connectivity concept (ports, component, Test Adapter, …) 3.test data (type definitions, templates)  Behaviour Model Editor with 3 specialised perspectives Step2: Creation of Service Behaviour Model Editors FSM Editor Test Data Editor Connectivity Editor

9 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes9 Hochschule Osnabrück University of Applied Sciences Composition of FSM (Finite State Machine)  sFSM (sub Finite State Machine)  Reusable templates, which represent predefined message flows from standards  internal transitions are fixed, external transitions used to realise composition  usually protocol specific (e.g., SIP, TCP, HTTP)  Composition of sFSM with Transaction User sFSM-M1 sFSM-M2

10 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes10 Hochschule Osnabrück University of Applied Sciences The FSM Connector: Transaction User (TU)  interfaces of the sub finite state machines have the TU as sender or receiver  acts as mediator between possible client and server roles  does not contain information about the service implementation

11 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes11 Hochschule Osnabrück University of Applied Sciences FSM Editor

12 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes12 Hochschule Osnabrück University of Applied Sciences Connectivity Concept: Composition of SUT/Test Environment Description ElementDescription Compontenttest component; contains the server and client specific protocol endpoints (Ports) PortInterface between test environment and SUT (e.g. SIP Port or HTTP Port) Global TimerTimer; usable in any state or as event on transition; ensures a state is left in or after a specific amount of time ActionReactions to an event; set on transition; either send a message or manipulate variable/timer GuardAdditional conditions for transitions; validates content of a message or value of a variable Primitive VariablesSimple variables; used in context with Guards

13 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes13 Hochschule Osnabrück University of Applied Sciences Connectivity Concept: Mapping to TTCN-3

14 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes14 Hochschule Osnabrück University of Applied Sciences Test Data Editor  create and edit message templates  message structure reflected in tree view  specific for one port and its protocol Example

15 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes15 Hochschule Osnabrück University of Applied Sciences Behaviour Model Editors Test Data Editor Connectivity Editor (TTCN-3 ports, timer, …) Abstract Test Case Generator TTCN-3 FSM Editor FSM Path- finder FSM & Connectivity Parser TTCN-3 Code Generator Behaviour Model Analyser Step 3: Abstract Test Case Generation

16 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes16 Hochschule Osnabrück University of Applied Sciences Test Case Generation: FSM Pathfinder Path  set of states and transitions between start- and end-state of FSM Pathfinder  finds all possible paths in FSM between start and end state  FSM considered as deterministic  branching = new test case  employs depth-first-search

17 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes17 Hochschule Osnabrück University of Applied Sciences Test Case Generation: FSM Parser s1s2 p1.msg/p1.msg2 function s1_1() runs on c1 { p1.send(msg); alt { p1.receive(msg2) -> …. { s2_1(); } } Each path converted into test case by FSM Parser  state converted into a TTCN-3 function body  content of function specified by outgoing transition  FSM written from the service’s point of view  message based actions must be inverted

18 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes18 Hochschule Osnabrück University of Applied Sciences Test Case Generation: Connectivity Parser C omponent D efinition N ame of Component T imer Primitive V ariables M essage Variables P orts Type of Port Name of Port Parameter own block in editor; connected with comp. automatically generated for each message template + system component (only ports and static name)  generates component using parameter from Connectivity Editor

19 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes19 Hochschule Osnabrück University of Applied Sciences Test Adapter configuration file Name of PortProtocol (TCP/UDP) Role (Server/Client)Remote IP / Port Local IP / Port Parameter/Port Port Definition Name Type send/receivable Message Types Parameter reference in model Test Case Generation: Connectivity Parser  generates port using parameter from Connectivity Editor  generates configuration file for Test Adapter (parameter provided in Ports)

20 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes20 Hochschule Osnabrück University of Applied Sciences Test Case Generation: TTCN-3 Code Generator  Writes the acquired / generated data as TTCN-3 code using Velocity* * Java based Template Engine (http://velocity.apache.org)

21 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes21 Hochschule Osnabrück University of Applied Sciences Step 4: Test Execution  TTCN-3 code will be executed after the code generation has been completed by the Test Case Generator  Execution realised within a Test Environment (e.g. TTWorkbench)  Test results are stored in a database to measure the development progress  Iterative delta testing: only new or modified test cases executed  Test Framework for synchronisation of test developer and service developer

22 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes22 Hochschule Osnabrück University of Applied Sciences Conclusion  Novelty: New approach eases the generation of test cases by 1.composing predefined finite state machines (FSM) for protocol sequences to a behaviour model (BM) of a service. 2.From the BM a TTCN-3 test suite is automatically derived. 3.The new concept of Transaction User (TU) enables testing of value added services  Benefits: Integration of Service Creation and Testing  Development of functional tests in parallel to service development  ensuring automated TTCN-3 based testing of services  Testing is integrated in a service creation environment allowing for regression tests  Re-Use by Others: General Applicability  test generation can be used for any SCE  generic configurable test adapter based on Java for TTCN-3 (e.g. for TCP, UDP,…)  universal codec for generation of test patterns has been implemented

23 TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes23 Hochschule Osnabrück University of Applied Sciences References 1.P. Wacht et al.: A New Approach to Design Graphically Functional Tests for Communication Services, IEEE NTMS, Paris, 7-10 February 2011. 2.P. Wacht et. al.: ComGeneration: die Dienstebeschreibung als Basis für automatisiertes Testen, VDE/ITG Fachtagung Mobilkommunikation, Osnabrück, 18-19 May 2011. 3.A. Lehmann et al.: “TeamCom: A Service Creation Platform for Next Generation Networks”, IEEE ICIW 2009, Venice/Mestre, Italy, 24-28 May 2009.


Download ppt "TTCN-3 User Conference, June 7-9, 2011, Bled, SloveniaProf. Dr.-Ing. Ralf Tönjes1 Hochschule Osnabrück University of Applied Sciences Contact:"

Similar presentations


Ads by Google