Difference between revisions of "OtfWorkflowDesigner"
Line 1: | Line 1: | ||
{{DISPLAYTITLE:Open Test Framework - Workflow Designer (OTX Designer)}}[[Category:OTF]] | {{DISPLAYTITLE:Open Test Framework - Workflow Designer (OTX Designer)}}[[Category:OTF]] | ||
− | |||
==Overview== | ==Overview== | ||
− | The Workflow Designer is the central interface to insert and arrange OTX nodes. It helps the authors create, edit and understand the test sequences graphically. The following main tasks will be implemented with the OTX Designer: | + | The '''Workflow Designer (OTX Designer)''' is the central interface to insert and arrange OTX nodes of a test sequence. It helps the authors create, edit and understand the test sequences graphically. The following main tasks will be implemented with the OTX Designer: |
* Specification | * Specification |
Revision as of 08:02, 24 September 2014
Contents
Overview
The Workflow Designer (OTX Designer) is the central interface to insert and arrange OTX nodes of a test sequence. It helps the authors create, edit and understand the test sequences graphically. The following main tasks will be implemented with the OTX Designer:
- Specification
- Realization
- Documentation
The structure and features of the Workflow Designer are described in the following sections.
Structure
In the Workflow Designer, test sequences can be edited graphically, see the image below. The Designer may consist of one or many procedure tabs, each tab corresponds to a procedure (a workflow). Within a workflow, various activities (OTX nodes) are drawn together into a sequence on a white page. These activities can be configured through the dockable Properties window or the Properties dialog box. The activities are executed sequentially from top to bottom.
![]() |
Workflow Designer helps with editing OTX sequences graphically |
The sequences are presented in the form of a generic flowchart. This means that the author has only the ability to add individual items to, edit and adjust the presentation details. However, it has no direct influence on the position of the elements. It may include such activities so do not move the mouse to another location, such as in MS Visio. This supports the generic approach of OTX and has the following advantages:
- The representation is generated solely from the OTX data without further meta data
- The depiction of the sequence is independent of the flavor of the author
- The same OTX sequence is the same on different computers
- The author does not have to worry about layout details
A designer consists of the 3 following main parts (see the image above):
- The procedure tittle bar
- The procedure head area
- The sequence drawing page.
Procedure Title Bar
The title bar displays the name of the current procedure, it helps users manage many opened procedures. You can arrange the order of the opened procedures by dragging and dropping the title bars to the desired position. If there are so many opened procedures, some procedures may be hidden. To display the hidden procedures, click on the forward (">>") icon in the right end of the title bars and select the procedure you want to display. You can move to the next procedure tab (i.e. the tab on the right of the current procedure) with the shortcut CTRL+TAB.
Each title bar has a context menu, right click on the title bar, a context menu will be displayed with the following entries:
Menu entry | Description |
Close | Closes the current procedure. |
Close all except this | Closes all opened procedure except the current procedure. |
Open document folder | Opens the package folder containing the current document in a new window with Windows Explorer. |
Procedure Head Area
In the procedure head area, the relevant information of the procedure are presented below:
- Name
- Parameter (In-, Out- and InOut- parameters)
- ValidFor
- Implemented Signature
- Specification
Sequence drawing page
The drawing page contains the actual test sequence of a procedure. It consists of a sequence of activities, see the image above.
Some elements in the Workflow Designer have the context menus which supports editing the element or adding variables or parameters for the procedure ect. Below are the short descriptions of these context menus:
Right click on any where in the drawing page except the activites (nodes), there will be a context menu with the following entries:
Menu entry | Description |
Show in SolutionExplorer | Finds and selects the procedure node of the current procedure in the Solution Explorer (expanding the parent item or scrolling the tree-view control, if necessary). |
New Procedure In-Parameter | Adds a new in-parameter to the current procedure. |
New Procedure Out-Parameter | Adds a new out-parameter to the current procedure. |
New Procedure In/Out-Parameter | Adds a new in/out-parameter to the current procedure. |
New Local Variable | Adds a new local variable to the current procedure. |
Right click on an activity (or one activity of the selected activities, see below), there will be a context menu with the following entries:
Menu entry | Description |
Cut | Cuts the activity or the selected activities. |
Copy | Copies the activity or the selected activities. |
Delete | Deletes the activity or the selected activities. |
Paste | Pastes the copied or cut activity (or selected activities) below the current activity. |
Add Comment | Adds a new comment and links the comment to the current activity. |
Surround With >> Group | Creates a new Group activity to surround the current activity or the selected activities (i.e. the activities will be moved into the new Group activity). |
Surround With >> Handler | Creates a new Handler activity to surround the current activity or the selected activities (i.e. the activities will be moved into the Try-branch of new Handler activity). |
Extract Procedure | Extracts the activity or the selected activities into a new procedure and creates a new ProcedureCall to call the new procedure. |
Disable/Enable | Disables/Enables the activity or the selected activities. Note that the disabled activities will not be executed and all the errors and warning related to these activities will not be displayed except the check rule Core-Chk011. |
New Local Variable | Adds a new local variable to the current procedure. |
Remove/Add Realisation | Removes/Adds realisation in the current activity. Note that you can only add realisation to some certain activities (EmptyBranch, EmptyParallel, EmptyHandler, Group, EmptyGroup, EmptyMutexGroup). |
Toogle Breakpoint | Adds a break point to the current activity. |
Right click on a floating comment, there will be a context menu with the following entries:
Menu entry | Description |
Edit | Opens a dialog to edit the content of the comment. |
Delete | Deletes the comment. |
Delete link to (activity name) | Deletes the link between the comment and the activity (with mentioned name). |
Delete all links | Deletes all the links betweens the comment and other activities and other comments. |
Handling activities
Adding activities
To add an activity to the sequence, please follow the instructions as described below:
- Find the corresponding activity from the Toolbox.
- Drag the activity from the Toolbox into the sequence, note that there will be green plus signs displayed at the valid locations for this activity.
- Drop activity on one of the plus sign sothat the plus sign is replaced by the icon of the activity.
- If the insertion is not in the visible region of the sequence, drag the activity on one of the blue arrows at the edges of the Workflow Designer.
- The drawing page will be scrolled toward the corresponding direction to to show the hidden region, move the mouse pointer out of the blue arrow to stop scrolling (but still hold down the left-mouse button, i.e. still drag the activity).
- Drop the activity at the valid location sothat the activity is generated in the appropriate place.
- If you want to configure the activity, please use the Properties window or the Properties dialog box.
![]() |
Insert an Assignment activity from the Toolbox to the Workflow Designer using drag-and-drop |
Adding further realisations for activities
An activity may have more than one realisation, see OTX basic concepts, below is an example of adding further realisation for an activity:
- Drag an activity from the Toolbox into the sequence and drop it on a green plus sign (see example above).
- Drag another activity from the Toolbox into the sequence and drop it on the existing activity to add further realisation.
- When you see the context menu displays, select the entry "Integrate" in the context menu to integrate the second activity with the first activity as the further realisation.
- To add another realisation to the activity with many realisations, drag a new activity onto the display area of the realisations in the middle of the activity.
- There will be no context menu, the new activity will automtically become a further realisation in the activity.
- If you want to configure the realisation, click on the realisation icon in the activity with many realisations and use the Properties window or the Properties dialog box.
![]()
Besides using a new activity to add further realisation, you can also use an existing activity to add further realisation by drag-and-drop.
Replacing activities
You can replace an existing activity with another activity. If the existing activity has a specification, the new activity will inherit the same specification. To replace an activity, please proceed as follows:
- Drag an activity from the Toolbox into the sequence and drop it on an existing activity in the workflow.
- When the context menu appears, select the entry "Replace" and the existing activity will be replaced with the new activity.
![]()
Besides using a new activity to replace an existing activity, you can also use an existing activity to replace another activity by drag-and-drop.
Editing a sequence
In the Workflow Designer, one or more activities (nodes) can be copied, cut, pasted , or deleted, please proceed as follows:
- Select an activity in the sequence, or select many activities by holding the CTRL key down and clicking on the all activities you want to select. You can also hold the SHIFT key and use mouse to drag a retangle to select all the covered activities.
- To deselect some of the selected activities, hold down CTRL key and click on each activity you want to deselect.
- There are many ways to copy, cut, delete or paste the selected activities:
3.1 Use the keyboard shortcuts (CTRL+C: Copy, CTRL+X: Cut, DEL: Delete, CTRL+V: Paste) with the selected activities, note that you can paste on an activity or on an empty flow (where green pluses appear). 3.2 Use the context menu by right-clicking on one of the selected activities (or on an empty flow to paste) and selecting the corresponding entry (see the context menu description above). 3.3 Use the corresponding command buttons in the tab "Start" of the Ribbon. 3.4 To copy and paste the selected activities by drag-and-drop: click and hold the mouse on one of the selected activities and drag them to the position you want to copy and paste (do not release the mouse), then hold down the CTRL key and release the mouse at the position (i.e. drop the activities at the position while holding the CTRL key). - To move the selected activities, click and hold the mouse on one of the selected activities and drag them onto the new position (it must be a valid location i.e. where the green pluses appear) and release the mouse.
Within a sequence, you can move the view of the sequence up/down or left/right by using the mouse wheel, the arrow keys or the scroll bars.
To zoom in and out of a sequence, you can hold down the CTRL key and use the mouse wheel, or you can use the slider in the Status Bar, see the image below. Note, you can only change the zoom level from 10% to 400%. Beside the slider, you can find the "Reset zoom factor" command to set the designer appearance back to the default zoom (i.e. 100%), or the "Fit to window" command to reduce the zoom sothat the entire sequence may be displayed, note that the minimum zoom percentage is 10%. You can also find the "Reset zoom factor" and the "Fit to window" commands in the "Display" tab of the Ribbon.
Besides zooming the sequence, you can enlarge the sequence display area by using the "Maximum work area" command which allows for setting all the opened tool windows to auto hide and minimizes the Ribbon. If you want all the auto hide tool windows back, you can use the "Standard layout" command which allows for docking all the tool windows. You can find these two commands in the Status Bar (see the image below) or in the "Display" tab of the Ribbon.
![]() |
Zooming within the workflow designer |
Adjusting the display of the sequence
The OTF allows for adjusting the display of the sequence such as the detail level, the display quality, or the max width of the activities ect. To adjust the display of the sequence, you can find the corresponding commands in the "Display" tab of the Ribbon.
In the "Designer Appearance" section of the "Display" tab, there are 6 detail levels for the presentation of the activities as shown below:
Detail level | Description |
1 - All | Shows all available information within an activity. |
2 - Standard | Shows all available information except the specification within an activity. |
3 - Compressed | Shows only the name and generated text of the function of an activity. |
4 - Test Step | Shows only the name, the "ValidFor" property and the specification of an activity, and sets the Test Step mode active. |
5 - Code | Shows the specification and the generated text of the function of an activity in pseudo code style. |
6 - Specification | Shows only the name and the specification of an activity. |
Here in the "Display" tab, you can also set the the max width of the activities in the sequence by selecting the size in the "Max Width" combo-box. If you check the option "Fixed Width" all the activities will be displayed exactly according to the selected max width; otherwise, only the activities with the display content longer than the max width will be limited by the max width.
Besides, you can use the command "Quality of Display" in the "Display" tab to set the display quality to High or to Low. The low display quality will turn off the softening and shadow effects, which is suitable in case that you want to see the text clearer or your computer performs slow with the softening and shadow effects. You can also find this command in the status bar at the bottom of the OTF (see the image above).
Finally, you can show or hide all the floating comments in the sequence by using the command "Display Comments". You can also find this command in the status bar at the bottom of the OTF (see the image above).
Capturing and printing a sequence
Capturing a sequence
You can capture the image of the current sequence by using the command "Copy as Bitmap" in the "Start" tab of the Ribbon. The captured image of the sequence is the same as it is presented in the OTF (see the previous section for the sequence display adjustment). The image will be copied to clipboard, you can then paste the image in another application such as MS Word ect.
Printing a sequence
You can print a sequence. Proceed as follows:
- Set the detail level of sequence as you desires. The sequence is printed as it is presented (see the previous section for the sequence display adjustment).
- Press CTRL+P. It will open the "File" menu in the Ribbon, and go to the "Print" tab.
- With the "Page Setup ..." button, you can set the properties of the page and select a printer.
- Click on the "Print ..." button to print the sequence.
![]() |
Printing a sequence with page preview |