User Tools

Site Tools


gui_html_adaptor

Differences

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

Link to this comparison view

gui_html_adaptor [2024/12/09 10:25]
montse [Functions]
gui_html_adaptor [2024/12/09 10:49] (current)
montse [Functions]
Line 53: Line 53:
   * **closeAllWindows():​** closes all the instanced adaptor windows. Do not need input parameters.  ​   * **closeAllWindows():​** closes all the instanced adaptor windows. Do not need input parameters.  ​
  
-  * **closeOthersWindows():​** ​close all extra open windows, leaving the main one active. Do not need input parameters.+  * **closeOthersWindows():​** ​closes ​all extra open windows, leaving the main one active. Do not need input parameters.
  
   * **closeWindow():​** closes the test browser. //We can not use the closeWindow function if we will later use the openUrl function, because we will lose the HTML GUI Adaptor instance.// It needs an input parameter element, to select any element on the page we want to close. ​   * **closeWindow():​** closes the test browser. //We can not use the closeWindow function if we will later use the openUrl function, because we will lose the HTML GUI Adaptor instance.// It needs an input parameter element, to select any element on the page we want to close. ​
Line 94: Line 94:
   * **focus():​** function to put the focus on a element. With the Element parameter the user indicate where the focus will be.   * **focus():​** function to put the focus on a element. With the Element parameter the user indicate where the focus will be.
  
-  * **generateFileAsEvidence:​** ​generate ​a text file as evidence for the test.+  * **generateFileAsEvidence:​** ​generates ​a text file as evidence for the test.
  
   * **getAttribute(Attribute):​** gets text, value, attribute of the element and saves to variable.\\ If the attribute is present and the field disabled, true is returned. If the attribute doesn’t exist and you can edit the field, an empty string is returned with a message in the log saying that the attribute doesn’t exist. The function returns an empty string “ ” for any attribute value that doesn’t exist.   * **getAttribute(Attribute):​** gets text, value, attribute of the element and saves to variable.\\ If the attribute is present and the field disabled, true is returned. If the attribute doesn’t exist and you can edit the field, an empty string is returned with a message in the log saying that the attribute doesn’t exist. The function returns an empty string “ ” for any attribute value that doesn’t exist.
Line 205: Line 205:
   * **waitForElement(Element,​ TimeInSeconds):​** waits for the element to appear. Until it’s available in the HTML code, even if it is not visible. By default webdriver will wait 30 seconds (We can decrease or increase this time in the code). Visibility means that the element is not only displayed but also has a height and width that is greater than 0.   * **waitForElement(Element,​ TimeInSeconds):​** waits for the element to appear. Until it’s available in the HTML code, even if it is not visible. By default webdriver will wait 30 seconds (We can decrease or increase this time in the code). Visibility means that the element is not only displayed but also has a height and width that is greater than 0.
  
-  * **waitForElementTime():​** ​Tthis function waits for the element until it “appears”,​ that is until the HTML code is available even though the element is not visible yet (the visibility of the element mean that it is not shown but it already has height and weight higher than 0) . The webdriver waits for 30 seconds by default and returns the time with a double. The input parameter TimeInSeconds is to change the default time, and the Element parameter is to indicate which element we want to use.+  * **waitForElementTime():​** ​this function waits for the element until it “appears”,​ that is until the HTML code is available even though the element is not visible yet (the visibility of the element mean that it is not shown but it already has height and weight higher than 0) . The webdriver waits for 30 seconds by default and returns the time with a double. The input parameter TimeInSeconds is to change the default time, and the Element parameter is to indicate which element we want to use.
  
  
gui_html_adaptor.1733739939.txt.gz · Last modified: 2024/12/09 10:25 by montse