IBM
Contents Index Previous Next



Selecting Browser Items


The Selector is a tool that you may use when you want to make selections of Browser items. Before you apply the Selector, the Browser must already contain a selection.Then you can specify, with the Selector, if you want to increase, decrease or replace the existing selection.

Based on the selections in the Browser, you can make sub Browsers. A sub Browser works as the normal TTCN Browser, but it does not contain the entire test suite - only selected parts.

What You Will Learn

Selection 1

Suppose that you wish to select all the tables in the test suite that reference the PDU called SEND:

  1. Deselect the entire test suite.
  2. Select the single PDU called SEND.
  3. Select Selector from the Browser Tools menu.
    The Selector dialog is opened:

Figure 50 : The Selector dialog

  1. Select the Extend option in Select Mode.
  2. Choose the Referenced by option in the Relations box.
    You do not have to change any other options.
  3. Click the Select button.
    Now take a look at the Browser. You should see that not only is the SEND PDU selected but also the constraint S1 and the test case TEST_CASE_1. Only these objects reference the SEND PDU. (You may have to scroll the Browser to see them all.)

Selection 2

As another example, suppose that you wish to find all behaviour tables that have the character 1 included in their identifier and have a PASS verdict in the table:

  1. Select the entire test suite.
  2. Select Selector from the Browser Tools menu.
    The Selector dialog is opened.
  3. Type 1 in the Name restriction field.
    This means that the names of the tables that you want to select should include the character 1.
  4. Select Test Case Dynamic Behaviour, Test Step Dynamic Behaviour and Default Dynamic Behaviour in the Type Restriction box.
  5. Type PASS in the Content restriction field.
    This means that there must be at least one occurrence of the word PASS in the selected tables.
  6. Select Restrict in the Select mode box.
    In other words, the intention is to select all behaviour tables that have a 1 in their names and that have a PASS substring in the contents of the table.
    The Analyze status and Relations options should not be set.
  7. Click the Select button.
    Only TEST_STEP_1 is selected in the Browser window.

Selection 3

Compare the result of the selection above with the following:

  1. Select the entire test suite.
  2. Apply the Selector with almost the same options as described above.
    • The difference is that you should remove PASS from the Content restriction field, i.e. the field should be empty.
  3. Click the Selector button.
    This time, both TEST_CASE_1 and TEST_STEP_1 are selected, because a PASS substring does not appear in the test case.

Creating a Sub Browser

It might be suitable at this point to create a sub Browser of the selection that you have just created (i.e. just the items TEST_CASE_1 and TEST_STEP_1):


http://www.ibm.com/rational
Contents Index Previous Next