Sample Visual Test: Using Decision Logic to Verify a Control Selection - Part 1 Scenario

Test Scenario

The tester wants to make a different set of selections against a ComboBox based on whether any value for the control has been previously selected. The tester wants one set of actions tested against the ComboBox if its existing text is empty (indicating it has not been selected), and a different action if not empty.

To do this, the tester sets up the visual test to evaluate whether the Text property of the control contains any text prior to performing actions against it. The decision logic uses the absence of text in the control's Text property to determine actions that will follow. The different set of actions based on the decision condition are part of the decision logic's If/Else construction. The tester also wants to report the outcome of the decision logic and the actions taken to the test results.