ºÝºÝߣ

ºÝºÝߣShare a Scribd company logo
TApp v.1
Test Automation Team
Arvie Bernal
Charles Kenneth Hallig
Jayson Dungo
Julian Garcia III
TApp
? About TApp
Creating and Running Tests
? Understanding Web Elements / Objects
? Understanding Graphical User Interface,
Test Cases, Test Steps and Test
Scenarios
? Understanding Configurations
? Running Tests
Bamboo Integration
? Bamboo requirement
About TApp
The Test Automation Application (TApp) is a solution to automate
testing as an integral part of the Software Development process.
TApp
Web Elements / Objects
CSS Selector
Name
Link Text / Partial Link Text
Web Elements / Objects
ID
Classname
XPath
Tagname
CSS Selectors
Selector Example Example description CSS
#id #firstname Selects the element with id="firstname" 1
* * Selects all elements 2
element p Selects all <p> elements 1
element,element div, p Selects all <div> elements and all <p> elements 1
element element div p Selects all <p> elements inside <div> elements 1
element>element div > p Selects all <p> elements where the parent is a <div> element 2
element+element div + p
Selects all <p> elements that are placed immediately after <div>
elements
2
element1~element2 p ~ ul Selects every <ul> element that are preceded by a <p> element 3
[attribute] [target] Selects all elements with a target attribute 2
CSS Selectors
Selector Example Example description CSS
[attribute=value] [target=_blank] Selects all elements with target="_blank" 2
[attribute~=value] [title~=flower]
Selects all elements with a title attribute containing
the word "flower"
2
[attribute|=value] [lang|=en]
Selects all elements with a lang attribute value
starting with "en"
2
[attribute^=value] a[href^="https"]
Selects every <a> element whose href attribute value
begins with "https"
3
[attribute$=value] a[href$=".pdf"]
Selects every <a> element whose href attribute value
ends with ".pdf"
3
[attribute*=value] a[href*="w3schools"]
Selects every <a> element whose href attribute value
contains the substring "w3schools"
3
:active a:active Selects the active link 1
::after p::after
Insert something after the content of each <p>
element
2
::before p::before
Insert something before the content of each <p>
element
2
CSS Selectors
Selector Example Example description CSS
:disabled input:disabled Selects every disabled <input> element 3
:empty p:empty
Selects every <p> element that has no children
(including text nodes)
3
:enabled input:enabled Selects every enabled <input> element 3
:first-child p:first-child
Selects every <p> element that is the first child of its
parent
2
::first-letter p::first-letter Selects the first letter of every <p> element 1
::first-line p::first-line Selects the first line of every <p> element 1
:first-of-type p:first-of-type
Selects every <p> element that is the first <p>
element of its parent
3
:focus input:focus Selects the input element which has focus 2
:hover a:hover Selects links on mouse over 1
CSS Selectors
Selector Example Example description CSS
:invalid input:invalid Selects all input elements with an invalid value 3
:lang(language) p:lang(it)
Selects every <p> element with a lang attribute equal to
"it" (Italian)
2
:last-child p:last-child
Selects every <p> element that is the last child of its
parent
3
:last-of-type p:last-of-type
Selects every <p> element that is the last <p> element
of its parent
3
:link a:link Selects all unvisited links 1
:not(selector) :not(p) Selects every element that is not a <p> element 3
:nth-child(n) p:nth-child(2)
Selects every <p> element that is the second child of its
parent
3
:nth-last-child(n) p:nth-last-child(2)
Selects every <p> element that is the second child of its
parent, counting from the last child
3
:nth-last-of-type(n) p:nth-last-of-type(2)
Selects every <p> element that is the second <p>
element of its parent, counting from the last child
3
CSS Selectors
Selector Example Example description CSS
:only-of-type p:only-of-type
Selects every <p> element that is the only <p>
element of its parent
3
:only-child p:only-child
Selects every <p> element that is the only child
of its parent
3
:optional input:optional
Selects input elements with no "required"
attribute
3
:out-of-range input:out-of-range
Selects input elements with a value outside a
specified range
3
:read-only input:read-only
Selects input elements with the "readonly"
attribute specified
3
:read-write input:read-write
Selects input elements with the "readonly"
attribute NOT specified
3
:required input:required
Selects input elements with the "required"
attribute specified
3
:root :root Selects the document's root element 3
::selection ::selection
Selects the portion of an element that is selected
by a user
CSS Selectors
Selector Example Example description CSS
:target #news:target
Selects the current active #news element (clicked on a URL
containing that anchor name)
3
:valid input:valid Selects all input elements with a valid value 3
:visited a:visited Selects all visited links 1
XPath Locators
Expression Description
nodename Selects all nodes with the name "nodename"
/ Selects from the root node
//
Selects nodes in the document from the current node that match the selection
no matter where they are
. Selects the current node
.. Selects the parent of the current node
@ Selects attributes
XPath uses path expressions to select nodes or node-sets in an XML document. The node is
selected by following a path or steps.
XPath Locators
Path
Expression
Result
bookstore Selects all nodes with the name "bookstore"
/bookstore
Selects the root element bookstoreNote: If the path starts with a slash ( / ) it
always represents an absolute path to an element!
bookstore/
book
Selects all book elements that are children of bookstore
//book Selects all book elements no matter where they are in the document
bookstore/
/book
Selects all book elements that are descendant of the bookstore element, no
matter where they are under the bookstore element
//@lang Selects all attributes that are named lang
Path expressions and the result of the expressions:
XPath Locators
Path Expression Result
/bookstore/book[1]
Selects the first book element that is the child of the bookstore element. Note: In IE 5,6,7,8,9 first node
is[0], but according to W3C, it is [1]. To solve this problem in IE, set the SelectionLanguage to XPath:
In JavaScript: xml.setProperty("SelectionLanguage","XPath");
/bookstore/book[last()] Selects the last book element that is the child of the bookstore element
/bookstore/book[last()-1] Selects the last but one book element that is the child of the bookstore element
/bookstore/book[position()<3] Selects the first two book elements that are children of the bookstore element
//title[@lang] Selects all the title elements that have an attribute named lang
//title[@lang='en'] Selects all the title elements that have a "lang" attribute with a value of "en"
/bookstore/book[price>35.00]
Selects all the book elements of the bookstore element that have a price element with a value greater
than 35.00
/bookstore/book[price>35.00]/title
Selects all the title elements of the book elements of the bookstore element that have a price element
with a value greater than 35.00
Predicates
Predicates are used to find a specific node or a node that contains a specific value.
Predicates are always embedded in square brackets.
In the table below we have listed some path expressions with predicates and the result of the expressions:
XPath Locators
Wildcard Description
* Matches any element node
@* Matches any attribute node
node() Matches any node of any kind
Selecting Unknown Nodes
XPath wildcards can be used to select unknown XML nodes.
Path
Expression
Result
/bookstore
/*
Selects all the child element nodes of the bookstore element
//* Selects all elements in the document
//title[@*] Selects all title elements which have at least one attribute of any kind
XPath Locators
Selecting Several Paths
By using the | operator in an XPath expression you can select several paths.
Path Expression Result
//book/title | //book/price Selects all the title AND price elements of all book elements
//title | //price Selects all the title AND price elements in the document
/bookstore/book/title | //price
Selects all the title elements of the book element of the
bookstore element AND all the price elements in the
document
Graphical User Interface
Main Configuration Window
List of Test Suites per project
List Test Cases within the Test Suite
Test Steps of the selected Test CaseOther available Test Cases
Option to Select All Test Cases
Option whether the Test Case will be ran during testing
Name of the selected Test Suite
Platform of the Suite and other options
Site to be tested
Root URL of the site
Headless execution
Failed step will terminate the testing
Recipient of the report
History of runs
Graphical User Interface
File Menu
TApp version
Create New Suite
Save Suite
Logout (will show again the Login Form)
Terminates TApp
Graphical User Interface
Run Menu
Runs the selected test suite
Graphical User Interface
Test Script Menu
Create or update test cases
Graphical User Interface
Tools Menu
Change User Password
Graphical User Interface
Icons
Save Suite/Configuration
Add/Edit Test Case
Run the test
Graphical User Interface
Test Script Generator
List of Test Script per project
Name of the Selected Test Script
Platform of the Test Script
Action to be done to Object
Object to find within the app/page
Sub-action to be done to
object with data referencing
Data to supply or select to
Conditions for validating
logical data from the object
Data to be validated
against the data
from the object
Add/Update test step to table
List of steps to be performed from the selected Test Script
Graphical User Interface
File Menu
Save Test Script
Graphical User Interface
Edit Menu
Copy the selected step
Paste above/below the selected step
Remove the selected step
Remove all test steps
Graphical User Interface
Icons
Save Test Script
Move selected row up
Move selected row down
Remove selected row
Clear Table
Graphical User Interface
Run Console
Name of the Test Suite and what browser it is executed
Pause the test execution
Test results
Path of the generated report
Test step details
Opens the .doc file of the test report
Test Cases
Creating Test Cases
Click Add/Edit Test Scripts in the Test Script menu
Click yes to create a new test caseSelect a platform
Test Cases
Adding Test Steps
Test Steps
Actions / Keyword
Object / KeywordValue
Option
Option Parameter
Validation Operator
Validation Data
Test Steps
Clicking an Object
Syntax
Click <object>
Test Steps
Typing Text
Syntax
From <object> type text <option
parameter>
Test Steps
Selecting Item From A List / Dropdown
Syntax
From <object> select item <option
parameter>
Test Steps
Searching For an Item
Syntax
From <object> search for <option
parameter>
Test Steps
Handling Alert Boxes
Syntax
From <alert> <select positive>
Test Steps
Handling Confirmation Boxes
Syntax
From <alert> <select positive / select
negative>
Test Steps
Handling Prompt Boxes
Syntax
From <alert> <select positive with text>
Test Steps
Passing an Object¡¯s Value To A Variable
Syntax
From <object> <store value to map>
To use the stored value, use
**map** <variable name>
Ex. **map** variableMap1
Test Steps
Passing the System¡¯s Date and Time
Syntax
**datetime** <longdate / shortdate /
custom_format>
longdate : September 14, 2016
shortdate : 09/14/16
Custom Format should follow the SimpleDateFormat item formats
Test Steps
Returning to the Previous Web Page
Syntax
Navigate Backwards
Test Steps
Validating an Object¡¯s Value
Syntax
Validate <object> if <validation operator>
<validation data>
Test Steps
Validating CSV, TAB and EXCEL Files
Syntax
Validate **file** <filename> if **colrow**
<column,row> <validation operator>
<validation data>
**file** - function that tells TApp that the supplied object is a physical file
**colrow** - function that parses the supplied parameter as column and row
To check the whole content of the file, just empty the Option Parameter field.
Test Steps
Validating XML File
Syntax
Validate **file** <filename> if **tag**
<tag/node> <validation operator>
<validation data>
**file** - function that tells TApp that the supplied object is a physical file
**tag** - function that parses the supplied parameter as XML tag/node/element
To check the whole content of the file, just empty the Option Parameter field.
Test Steps
Validating PDF File
Syntax
Validate **file** <filename> if **page**
<page number> <validation operator>
<validation data>
**file** - function that tells TApp that the supplied object is a physical file
To search on a specific page, use: **page**
Example: **page** <page number>
To search in specific page range, use: **pages**
Example: **pages** <starting page>-<ending page>
To check the whole content of the file, just empty the Option Parameter field.
Test Steps
Switching Toggle Buttons
Syntax
Switch <object> <to ON / to OFF>
Test Steps
Switching From a Native App To WebView
Syntax
Switch to WebView
Test Steps
Navigating to a Web Address
Syntax
Switch To WebView with URL <URL>
Using Well-formed URL
Using Base URL from Configuration
Base URL is http://anz-go-dev.aws.cambridge.edu.au/
Test Steps
Switching From WebView to Native App
Syntax
Switch To Native
Test Steps
Submitting Forms
Syntax
Submit Form
Test Steps
Accessing Elements Within an iFrame
Syntax
Switch To iFrame <iFrame name>
Test Steps
Exiting iFrames
Syntax
Switch To Default Web Content
Test Steps
Swiping Screens
Syntax
Swipe <object> <Left to Right / Right to
Left / Top to Bottom / Bottom to Top>
Test Steps
Calling Other Test Cases
Syntax
Execute Sub Script <testcase name>
Test Steps
Hovering Over Elements
Syntax
Hover To <object>
Test Steps
Handling Pop-Up Windows
Syntax
Switch to Child Window
Test Steps
Closing Pop-Up Windows
Syntax
Switch to Parent Window
Test Steps
Working With Tables
Syntax
Enter Table <object> get row no. of
<option parameter>
Test Steps
Exiting Tables
Syntax
Exit Table
Test Steps
Comparing Values Of Objects
Syntax
Compare <object1> if <validation
operator> <object2>
Test Steps
Delaying Step Execution
Syntax
Wait <value in seconds>
Test Steps
Closing the Mobile Application
Syntax
Close Mobile App
Test Steps
Moving a Mobile App To Run In the
Background
Syntax
Hide Mobile App to Background <value in
seconds>
Test Steps
Opening Mobile Applications
Syntax
Launch Mobile App
Test Steps
Setting WiFi, Data and Airplane Mode
Connectivity
Syntax
Turn Connection <WiFi / Data / Airplane>
<to ON / to OFF>
Test Steps
Setting the Device Orientation
Syntax
Rotate Orientation <device> <to portrait /
to landscape>
Test Steps
Escaping Certificate Error Notifications
Syntax
Bypass Certificate Error Notification
Test Steps
Validating CSS Properties
Syntax
Validate CSS of <object> if <css property>
(String) equals <validation data>
Note: CSS shorthand property is not recognized.
e.g. margin 10px 5px 15px 20px
Should be <css property> <validation data>:
margin-top 10px
margin-right 5px
margin-bottom 15px
margin-left 20px
Test Scenarios
Creating a Test Scenario
1. Click the Project where the Test Scenario will be created
2. Go to File and click New to create a Test Scenario
Test Scenarios
Creating a Test Scenario
A new Test Scenario will be created¡­
with a blank Test Configuration to fill-up
Test Scenarios
Adding Test Cases
After completing the Test Configuration
Double-click a Test Case to add it into the
Test Scenario or¡­
Test Scenarios
Adding Test Cases
Right-click on a Test Case and
choose ¡°Add to test plan¡±
Test Scenarios
Saving the Test Scenario
Save the Test Scenario after adding the Test Cases
Test Configuration
Web
Name of the selected Test Suite
Browsers where the Test Suite will be executed
Site to be tested
Root URL of the site
Headless execution Failed step will
terminate the testing
Recipient of the report
Test Configuration
Mobile - Android
Name of the selected Test Suite
Browsers where the Test Suite will be executed
Option to use Actual device or emulator
Unique ID of the actual device
Headless execution Failed step will
terminate the testing
Recipient of the report
Emulator properties
Android app location
Package name of app
Test Configuration
Mobile - iOS
Name of the selected Test Suite
Option to use Actual device or simulator
Unique ID of the actual device
Headless execution Failed step will
terminate the testing
Recipient of the report
iOS app location
Actual device/emulator properties
Running Tests
Executing Automated Tests
Find the Test Scenario that you want to run
Click the ¡°Run Test¡± button or press F5 on your keyboard
Running Tests
Run Console and Browser
The Run Console and the
browser specified will appear
After the test is done, you can open
the view the report by clicking
¡°Open Generated Report¡±
Running Tests
Generated Report ¨C Word File
Running Tests
Generated Report ¨C HTML File
Bamboo Integration
Run Tests on Remote Machine
Command line syntax:
Tappconsole [switch] [arguments]
Arguments:
-s or --suite (e.g. tapp_demo) *this is a required argument
-b or --browser (e.g. firefox, chrome)
-u or --url (e.g. http://www.google.com)
-h or --headlessexecution (e.g. true or false)
-r or --runinremoteserver (e.g. true or false)
-c or --consolerun (e.g. true or false)
-udid or --usedeviceid (e.g. LGD855ba0fc069)
Sample Call:
Tappconsole -s ¡°tapp_demo¡±
**Enclose arguments in double-quotes if a space is present in the test suite name

More Related Content

TApp Documentation

  • 1. TApp v.1 Test Automation Team Arvie Bernal Charles Kenneth Hallig Jayson Dungo Julian Garcia III
  • 2. TApp ? About TApp Creating and Running Tests ? Understanding Web Elements / Objects ? Understanding Graphical User Interface, Test Cases, Test Steps and Test Scenarios ? Understanding Configurations ? Running Tests Bamboo Integration ? Bamboo requirement
  • 3. About TApp The Test Automation Application (TApp) is a solution to automate testing as an integral part of the Software Development process. TApp
  • 4. Web Elements / Objects CSS Selector Name Link Text / Partial Link Text
  • 5. Web Elements / Objects ID Classname XPath Tagname
  • 6. CSS Selectors Selector Example Example description CSS #id #firstname Selects the element with id="firstname" 1 * * Selects all elements 2 element p Selects all <p> elements 1 element,element div, p Selects all <div> elements and all <p> elements 1 element element div p Selects all <p> elements inside <div> elements 1 element>element div > p Selects all <p> elements where the parent is a <div> element 2 element+element div + p Selects all <p> elements that are placed immediately after <div> elements 2 element1~element2 p ~ ul Selects every <ul> element that are preceded by a <p> element 3 [attribute] [target] Selects all elements with a target attribute 2
  • 7. CSS Selectors Selector Example Example description CSS [attribute=value] [target=_blank] Selects all elements with target="_blank" 2 [attribute~=value] [title~=flower] Selects all elements with a title attribute containing the word "flower" 2 [attribute|=value] [lang|=en] Selects all elements with a lang attribute value starting with "en" 2 [attribute^=value] a[href^="https"] Selects every <a> element whose href attribute value begins with "https" 3 [attribute$=value] a[href$=".pdf"] Selects every <a> element whose href attribute value ends with ".pdf" 3 [attribute*=value] a[href*="w3schools"] Selects every <a> element whose href attribute value contains the substring "w3schools" 3 :active a:active Selects the active link 1 ::after p::after Insert something after the content of each <p> element 2 ::before p::before Insert something before the content of each <p> element 2
  • 8. CSS Selectors Selector Example Example description CSS :disabled input:disabled Selects every disabled <input> element 3 :empty p:empty Selects every <p> element that has no children (including text nodes) 3 :enabled input:enabled Selects every enabled <input> element 3 :first-child p:first-child Selects every <p> element that is the first child of its parent 2 ::first-letter p::first-letter Selects the first letter of every <p> element 1 ::first-line p::first-line Selects the first line of every <p> element 1 :first-of-type p:first-of-type Selects every <p> element that is the first <p> element of its parent 3 :focus input:focus Selects the input element which has focus 2 :hover a:hover Selects links on mouse over 1
  • 9. CSS Selectors Selector Example Example description CSS :invalid input:invalid Selects all input elements with an invalid value 3 :lang(language) p:lang(it) Selects every <p> element with a lang attribute equal to "it" (Italian) 2 :last-child p:last-child Selects every <p> element that is the last child of its parent 3 :last-of-type p:last-of-type Selects every <p> element that is the last <p> element of its parent 3 :link a:link Selects all unvisited links 1 :not(selector) :not(p) Selects every element that is not a <p> element 3 :nth-child(n) p:nth-child(2) Selects every <p> element that is the second child of its parent 3 :nth-last-child(n) p:nth-last-child(2) Selects every <p> element that is the second child of its parent, counting from the last child 3 :nth-last-of-type(n) p:nth-last-of-type(2) Selects every <p> element that is the second <p> element of its parent, counting from the last child 3
  • 10. CSS Selectors Selector Example Example description CSS :only-of-type p:only-of-type Selects every <p> element that is the only <p> element of its parent 3 :only-child p:only-child Selects every <p> element that is the only child of its parent 3 :optional input:optional Selects input elements with no "required" attribute 3 :out-of-range input:out-of-range Selects input elements with a value outside a specified range 3 :read-only input:read-only Selects input elements with the "readonly" attribute specified 3 :read-write input:read-write Selects input elements with the "readonly" attribute NOT specified 3 :required input:required Selects input elements with the "required" attribute specified 3 :root :root Selects the document's root element 3 ::selection ::selection Selects the portion of an element that is selected by a user
  • 11. CSS Selectors Selector Example Example description CSS :target #news:target Selects the current active #news element (clicked on a URL containing that anchor name) 3 :valid input:valid Selects all input elements with a valid value 3 :visited a:visited Selects all visited links 1
  • 12. XPath Locators Expression Description nodename Selects all nodes with the name "nodename" / Selects from the root node // Selects nodes in the document from the current node that match the selection no matter where they are . Selects the current node .. Selects the parent of the current node @ Selects attributes XPath uses path expressions to select nodes or node-sets in an XML document. The node is selected by following a path or steps.
  • 13. XPath Locators Path Expression Result bookstore Selects all nodes with the name "bookstore" /bookstore Selects the root element bookstoreNote: If the path starts with a slash ( / ) it always represents an absolute path to an element! bookstore/ book Selects all book elements that are children of bookstore //book Selects all book elements no matter where they are in the document bookstore/ /book Selects all book elements that are descendant of the bookstore element, no matter where they are under the bookstore element //@lang Selects all attributes that are named lang Path expressions and the result of the expressions:
  • 14. XPath Locators Path Expression Result /bookstore/book[1] Selects the first book element that is the child of the bookstore element. Note: In IE 5,6,7,8,9 first node is[0], but according to W3C, it is [1]. To solve this problem in IE, set the SelectionLanguage to XPath: In JavaScript: xml.setProperty("SelectionLanguage","XPath"); /bookstore/book[last()] Selects the last book element that is the child of the bookstore element /bookstore/book[last()-1] Selects the last but one book element that is the child of the bookstore element /bookstore/book[position()<3] Selects the first two book elements that are children of the bookstore element //title[@lang] Selects all the title elements that have an attribute named lang //title[@lang='en'] Selects all the title elements that have a "lang" attribute with a value of "en" /bookstore/book[price>35.00] Selects all the book elements of the bookstore element that have a price element with a value greater than 35.00 /bookstore/book[price>35.00]/title Selects all the title elements of the book elements of the bookstore element that have a price element with a value greater than 35.00 Predicates Predicates are used to find a specific node or a node that contains a specific value. Predicates are always embedded in square brackets. In the table below we have listed some path expressions with predicates and the result of the expressions:
  • 15. XPath Locators Wildcard Description * Matches any element node @* Matches any attribute node node() Matches any node of any kind Selecting Unknown Nodes XPath wildcards can be used to select unknown XML nodes. Path Expression Result /bookstore /* Selects all the child element nodes of the bookstore element //* Selects all elements in the document //title[@*] Selects all title elements which have at least one attribute of any kind
  • 16. XPath Locators Selecting Several Paths By using the | operator in an XPath expression you can select several paths. Path Expression Result //book/title | //book/price Selects all the title AND price elements of all book elements //title | //price Selects all the title AND price elements in the document /bookstore/book/title | //price Selects all the title elements of the book element of the bookstore element AND all the price elements in the document
  • 17. Graphical User Interface Main Configuration Window List of Test Suites per project List Test Cases within the Test Suite Test Steps of the selected Test CaseOther available Test Cases Option to Select All Test Cases Option whether the Test Case will be ran during testing Name of the selected Test Suite Platform of the Suite and other options Site to be tested Root URL of the site Headless execution Failed step will terminate the testing Recipient of the report History of runs
  • 18. Graphical User Interface File Menu TApp version Create New Suite Save Suite Logout (will show again the Login Form) Terminates TApp
  • 19. Graphical User Interface Run Menu Runs the selected test suite
  • 20. Graphical User Interface Test Script Menu Create or update test cases
  • 21. Graphical User Interface Tools Menu Change User Password
  • 22. Graphical User Interface Icons Save Suite/Configuration Add/Edit Test Case Run the test
  • 23. Graphical User Interface Test Script Generator List of Test Script per project Name of the Selected Test Script Platform of the Test Script Action to be done to Object Object to find within the app/page Sub-action to be done to object with data referencing Data to supply or select to Conditions for validating logical data from the object Data to be validated against the data from the object Add/Update test step to table List of steps to be performed from the selected Test Script
  • 24. Graphical User Interface File Menu Save Test Script
  • 25. Graphical User Interface Edit Menu Copy the selected step Paste above/below the selected step Remove the selected step Remove all test steps
  • 26. Graphical User Interface Icons Save Test Script Move selected row up Move selected row down Remove selected row Clear Table
  • 27. Graphical User Interface Run Console Name of the Test Suite and what browser it is executed Pause the test execution Test results Path of the generated report Test step details Opens the .doc file of the test report
  • 28. Test Cases Creating Test Cases Click Add/Edit Test Scripts in the Test Script menu Click yes to create a new test caseSelect a platform
  • 30. Test Steps Actions / Keyword Object / KeywordValue Option Option Parameter Validation Operator Validation Data
  • 31. Test Steps Clicking an Object Syntax Click <object>
  • 32. Test Steps Typing Text Syntax From <object> type text <option parameter>
  • 33. Test Steps Selecting Item From A List / Dropdown Syntax From <object> select item <option parameter>
  • 34. Test Steps Searching For an Item Syntax From <object> search for <option parameter>
  • 35. Test Steps Handling Alert Boxes Syntax From <alert> <select positive>
  • 36. Test Steps Handling Confirmation Boxes Syntax From <alert> <select positive / select negative>
  • 37. Test Steps Handling Prompt Boxes Syntax From <alert> <select positive with text>
  • 38. Test Steps Passing an Object¡¯s Value To A Variable Syntax From <object> <store value to map> To use the stored value, use **map** <variable name> Ex. **map** variableMap1
  • 39. Test Steps Passing the System¡¯s Date and Time Syntax **datetime** <longdate / shortdate / custom_format> longdate : September 14, 2016 shortdate : 09/14/16 Custom Format should follow the SimpleDateFormat item formats
  • 40. Test Steps Returning to the Previous Web Page Syntax Navigate Backwards
  • 41. Test Steps Validating an Object¡¯s Value Syntax Validate <object> if <validation operator> <validation data>
  • 42. Test Steps Validating CSV, TAB and EXCEL Files Syntax Validate **file** <filename> if **colrow** <column,row> <validation operator> <validation data> **file** - function that tells TApp that the supplied object is a physical file **colrow** - function that parses the supplied parameter as column and row To check the whole content of the file, just empty the Option Parameter field.
  • 43. Test Steps Validating XML File Syntax Validate **file** <filename> if **tag** <tag/node> <validation operator> <validation data> **file** - function that tells TApp that the supplied object is a physical file **tag** - function that parses the supplied parameter as XML tag/node/element To check the whole content of the file, just empty the Option Parameter field.
  • 44. Test Steps Validating PDF File Syntax Validate **file** <filename> if **page** <page number> <validation operator> <validation data> **file** - function that tells TApp that the supplied object is a physical file To search on a specific page, use: **page** Example: **page** <page number> To search in specific page range, use: **pages** Example: **pages** <starting page>-<ending page> To check the whole content of the file, just empty the Option Parameter field.
  • 45. Test Steps Switching Toggle Buttons Syntax Switch <object> <to ON / to OFF>
  • 46. Test Steps Switching From a Native App To WebView Syntax Switch to WebView
  • 47. Test Steps Navigating to a Web Address Syntax Switch To WebView with URL <URL> Using Well-formed URL Using Base URL from Configuration Base URL is http://anz-go-dev.aws.cambridge.edu.au/
  • 48. Test Steps Switching From WebView to Native App Syntax Switch To Native
  • 50. Test Steps Accessing Elements Within an iFrame Syntax Switch To iFrame <iFrame name>
  • 52. Test Steps Swiping Screens Syntax Swipe <object> <Left to Right / Right to Left / Top to Bottom / Bottom to Top>
  • 53. Test Steps Calling Other Test Cases Syntax Execute Sub Script <testcase name>
  • 54. Test Steps Hovering Over Elements Syntax Hover To <object>
  • 55. Test Steps Handling Pop-Up Windows Syntax Switch to Child Window
  • 56. Test Steps Closing Pop-Up Windows Syntax Switch to Parent Window
  • 57. Test Steps Working With Tables Syntax Enter Table <object> get row no. of <option parameter>
  • 59. Test Steps Comparing Values Of Objects Syntax Compare <object1> if <validation operator> <object2>
  • 60. Test Steps Delaying Step Execution Syntax Wait <value in seconds>
  • 61. Test Steps Closing the Mobile Application Syntax Close Mobile App
  • 62. Test Steps Moving a Mobile App To Run In the Background Syntax Hide Mobile App to Background <value in seconds>
  • 63. Test Steps Opening Mobile Applications Syntax Launch Mobile App
  • 64. Test Steps Setting WiFi, Data and Airplane Mode Connectivity Syntax Turn Connection <WiFi / Data / Airplane> <to ON / to OFF>
  • 65. Test Steps Setting the Device Orientation Syntax Rotate Orientation <device> <to portrait / to landscape>
  • 66. Test Steps Escaping Certificate Error Notifications Syntax Bypass Certificate Error Notification
  • 67. Test Steps Validating CSS Properties Syntax Validate CSS of <object> if <css property> (String) equals <validation data> Note: CSS shorthand property is not recognized. e.g. margin 10px 5px 15px 20px Should be <css property> <validation data>: margin-top 10px margin-right 5px margin-bottom 15px margin-left 20px
  • 68. Test Scenarios Creating a Test Scenario 1. Click the Project where the Test Scenario will be created 2. Go to File and click New to create a Test Scenario
  • 69. Test Scenarios Creating a Test Scenario A new Test Scenario will be created¡­ with a blank Test Configuration to fill-up
  • 70. Test Scenarios Adding Test Cases After completing the Test Configuration Double-click a Test Case to add it into the Test Scenario or¡­
  • 71. Test Scenarios Adding Test Cases Right-click on a Test Case and choose ¡°Add to test plan¡±
  • 72. Test Scenarios Saving the Test Scenario Save the Test Scenario after adding the Test Cases
  • 73. Test Configuration Web Name of the selected Test Suite Browsers where the Test Suite will be executed Site to be tested Root URL of the site Headless execution Failed step will terminate the testing Recipient of the report
  • 74. Test Configuration Mobile - Android Name of the selected Test Suite Browsers where the Test Suite will be executed Option to use Actual device or emulator Unique ID of the actual device Headless execution Failed step will terminate the testing Recipient of the report Emulator properties Android app location Package name of app
  • 75. Test Configuration Mobile - iOS Name of the selected Test Suite Option to use Actual device or simulator Unique ID of the actual device Headless execution Failed step will terminate the testing Recipient of the report iOS app location Actual device/emulator properties
  • 76. Running Tests Executing Automated Tests Find the Test Scenario that you want to run Click the ¡°Run Test¡± button or press F5 on your keyboard
  • 77. Running Tests Run Console and Browser The Run Console and the browser specified will appear After the test is done, you can open the view the report by clicking ¡°Open Generated Report¡±
  • 80. Bamboo Integration Run Tests on Remote Machine Command line syntax: Tappconsole [switch] [arguments] Arguments: -s or --suite (e.g. tapp_demo) *this is a required argument -b or --browser (e.g. firefox, chrome) -u or --url (e.g. http://www.google.com) -h or --headlessexecution (e.g. true or false) -r or --runinremoteserver (e.g. true or false) -c or --consolerun (e.g. true or false) -udid or --usedeviceid (e.g. LGD855ba0fc069) Sample Call: Tappconsole -s ¡°tapp_demo¡± **Enclose arguments in double-quotes if a space is present in the test suite name