Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision Both sides next revision
tutorial:scripting_state_model [2020/11/24 22:09]
admin [Activating plugins]
tutorial:scripting_state_model [2020/11/25 16:53]
admin [Activating plugins]
Line 112: Line 112:
    $SYS.log('Random phone#: ' + $RANDOM.randPhone('999-999-9999') );    $SYS.log('Random phone#: ' + $RANDOM.randPhone('999-999-9999') );
        
 +==== Web App Automation====
 For test automation, for example web application you would activate //Selenium// plugin.  Once you have the plugin activated, you will be able to use //$SELENIUM// to interact with your web application through //Selenium/WebDriver// For test automation, for example web application you would activate //Selenium// plugin.  Once you have the plugin activated, you will be able to use //$SELENIUM// to interact with your web application through //Selenium/WebDriver//
  
Line 117: Line 118:
  
    $SELENIUM.getWebDriver().findElement(org.openqa.selenium.By.id('Water').click();    $SELENIUM.getWebDriver().findElement(org.openqa.selenium.By.id('Water').click();
-   + 
 +=== Page Object===   
 You could also use //PAGES// tab to define page object: You could also use //PAGES// tab to define page object:
    //PAGES Script    //PAGES Script
Line 133: Line 135:
    $SYS.page('MainPage').element('DrinkWater').perform('click');    $SYS.page('MainPage').element('DrinkWater').perform('click');
        
 +=== Find Element Locator ===
 +Web element locator can be xpath, css or by id, etc. as supported by //Selenium//.
  
 +There are many browser add-on/extension tools that can help you find locators for web element very easily.  Check out [[../externalsources | External Sources]] for a list of such tools.
 + 
 ===== User variables ===== ===== User variables =====