Professional Documents
Culture Documents
DISCLAIMER
Verbatim copying and distribution of this entire article is permitted worldwide, without
royalty, in any medium, provided this notice is preserved.
Table of Contents
TABLE OF CONTENTS
1.
PURPOSE
2.
FRAMEWORK IMPLEMENTATION
2.1.
OF THE
DOCUMENT ........................................ 3
IN
SELENIUM .............................. 4
3.
SELENIUM RC SERVER
4.
5.
CALL
6.
USAGE
7.
TEST RESULTS
8.
TO
Open2Test.org
UP
....................................... 6
FRAMEWORK ............................................ 10
OF
KEYWORDS ............................................ 11
FOR A
Page ii
1.
Open2Test.org
Page 3
2.
2.1.
File\Folder
Name
Test Suite
Test Script
Object
Repository
Summary
Report
Screen Shot
Report
Detailed Report
Location
C:/Innovez/Selenium_Automation/Test_Suite.xls
C:/Innovez/Selenium_Automation/Test_Scripts/
C:/Innovez/Selenium_Automation/Test_Data/Object_Repository.xls
C:/Innovez/Selenium_Automation/Test_Reports/
C:/Innovez/Selenium_Automation/Test_Reports/ScreenShot_Repor
t/
C:/Innovez/Selenium_Automation/Test_Reports/Detailed_Report/
ObjectName
Username
Password
Login
Manage
Manage Projects
Open2Test.org
objects
ObjectIdentification
username
password
//input[@value='Login']
link=Manage
link=Manage Projects
and
define
ObjectType
TextBox
TextBox
Button
link
link
Page 4
it
in
Run
r
r
r
r
r
Test Driver
Mantis_Create Project
Mantis_Report Issue
Mantis_View Issue and Delete Project
Mantis_Fail
Call Tariff Addition and Amendment
Step
r
r
r
r
r
Open2Test.org
Operation
Object
Action
callaction
C:\Documents and Settings\Mantis\DemoSelenium\Innovez\Selenium_Automation\Test_Scripts\Login
Action.xls
perform
link;Manage Projects
click
wait
3
perform
Button;Create New Project
click
perform
Textbox;Project Name
set:Selenium
Page 5
3.
Selenium RC Server up
Starting the server:
java -jar selenium-server.jar interactive
Open2Test.org
Page 6
Open2Test.org
Page 7
4.
Open2Test.org
Page 8
Open2Test.org
Page 9
5.
Call to Framework
The Main.rb should be opened in the SciTE. Press F5 and this will call
the framework file associated with the test and perform the actions by
interpreting the keywords specified in the data table.
Instead of pressing F5, we are able to run the main.rb by command ruby
<main.rb>
Open2Test.org
Page 10
6.
Usage of Keywords
The keywords should be entered in Sheet1 of Microsoft Excel placed in
the Test Scripts folder. The syntax for the keywords can be found in the
Selenium Keyword Reference Dictionary Document. Below is an example of a
simple keyword-driven scripting.
Open2Test.org
Page 11
7.
Open2Test.org
Page 12
Open2Test.org
Page 13
8.
Resource Files
The resource files such as Framework Files, Shared Object Repositories,
and Environment Variables that are associated with the test can be
stored in the users machine and can be obtained during test execution.
Function libraries of the file type .rb, environment variables of file
type .excel, and object repositories of file type .excel can be placed
in the folder specified in the Utility Excel.
File\Folder
Name
Test Suite
Test Script
Object Repository
Summary Report
Screen Shot
Report
Detailed Report
Location
C:/Innovez/Selenium_Automation/Test_Suite.xls
C:/Innovez/Selenium_Automation/Test_Scripts/
C:/Innovez/Selenium_Automation/Test_Data/Object_Repository.xls
C:/Innovez/Selenium_Automation/Test_Reports/
C:/Innovez/Selenium_Automation/Test_Reports/ScreenShot_Report/
C:/Innovez/Selenium_Automation/Test_Reports/Detailed_Report/
Library files
1. Main.rb
2. Functionlibrary.rb
Open2Test.org
Page 14
Open2Test.org
Page 15
COPYRIGHT
This library is free software; you can redistribute it and/or modify it under the terms of the
GNU Library General Public License as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without
even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public License along with this
library; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
MA 02110-1301, USA.
Open2Test.org
Page 16