switch window
Switch to another window instance.
Name | Description | Type | Modifier |
---|---|---|---|
window | TestArchitect name of the window. | Interface Entity | None |
None
This action may be used within the following project items: test modules and user-defined actions.
Suppose you are testing a customer live chat service that offers the fastest way to provide customer support on your website. There are two identical windows, one for the client, and the other for the supporter. In your test procedures, you have to switch between the client window and supporter window. This ensures that whatever the client enquires will appear on the supporter window.
Action lines
definition variable1 variable2
identify windows live chat channel client supporter
 
window
switch window # client
 
message
enter request message # tm request message
 
window
switch window # supporter
 
message
check request message # tm request message
Result
- This action is dedicated to Generic WebDriver.
- Each window instance is assigned a unique ID, which is called window handle.
- This unique ID is necessary when you want to switch among several windows which have identical definitions.
- You can obtain the window handle of identical window instances by using the identify windows action.