Quantcast
Channel:
Viewing all articles
Browse latest Browse all 43798

Wiki Page: Testing Web Browser Using Web Shortcuts

$
0
0
When testing your Web Browser with iOS or Android you can use Web Shortcuts.  These methods are documented in SilkTest Help:- Contents How To... Edit Add New Operation/Command Operations/Commands Web Shortcuts. After setting your device (SetDevice()) and launching the browser (WebLaunch()), you will initially need to find the object you wish to test using WebFind(), before using the required method (Eg - WebClick, WebSendKeys) against it.  See steps below:- 1. Setting device and Launch Browser:- In your SilkMobile script you will first Set your device using SetDevice(), use Weblaunch() to launch the browser and then WebGet() to navigate to the URL you wish to test against (see screenshot):- 2. Finding the object to test:- Next you will be required to get the attribute of the object you wish to test.  Attributes you can use include: id, name, xpath, class, css, link and link_part. To find the particular attribute you can use a WebSpy tool.  Eg - there is a spy tool that comes built in with Internet explorer.   - Open Internet Explorer on your PC mahine. - Select Tools | Developer Tools (or F12). - Choose Find | Select Element by click (or arrow icon). - Click on the object you wish to test. - Click on the "Attributes" tab. - The attributes for the object will be shown.  (see screenshot). In you Silk Mobile script you will then use WebFind() method to find the control.   - In the "Method" parameter enter the attribute type you are using (Eg - ID). - In "Value" parameter use the attribute value that was obtained from the Web spy tool.  See Screenshot below for this method call:- 3. Perform the required action against the object:- You can then call the required action against the object.  Eg - WebClick(), WebSendKeys(). Repeat this procedure for each object you wish to interact with.

Viewing all articles
Browse latest Browse all 43798

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>