Você está na página 1de 23

'===============================================================================

==========================
' Name of the Script : CA Reports Underlying Source
Comaprision
' Scope of the Script : This test script covers 15 te
st cases related to the UnderlyingSourceComparison in Corporate Action Applicati
on
' Author : Shyam H D
' Description : CA Reports UnderlyingSourceCo
mparison
' Date and / or Version : 05-03-2009,version 1.0
'===============================================================================
============================
Sub CAReportsUnderlyingSourComparision()
'****Declaration of Environmental Variable
Environment.Value("strSheetName")= "UnderlyingSourceComparison"
'''''''''Test case count
Const TC_COUNT = 15
strVar = Environment("TestDir")
strIndVar = Split(strVar,"\",-1,1)
strBound = UBound(strIndVar)
strAllPath =""
For intPathCounter = 0 to strBound - 1
strAllPath = strAllPath & strIndVar(intPathCount
er) &"\"
Next
strPath = Trim(strPath)
strDataPath = strAllPath & "DataTables\"
strLibPath = strAllPath & "Function_Library\"
' Including the Library files where all the Scripts are saved
'ExecuteFile strLibPath & "CAReportsUnderlyingSourceComparisonTC
.vbs"
'****Adding MFLogin sheet to the dataTable and Importing the Inp
ut DataTable
DataTable.AddSheet "CALogin"
DataTable.ImportSheet strDataPath & "Login.xls","CALogin","CALog
in"
DataTable.AddSheet "UnderlyingSourceComparison"
DataTable.ImportSheet strDataPath & "CorporateActionsReports.xls
","UnderlyingSourceComparison","UnderlyingSourceComparison"
DataTable.AddSheet "ReportHeader"
DataTable.ImportSheet strDataPath & "CorporateActionsReports.xls
","ReportHeader","ReportHeader"
DataTable.AddSheet "HomePageVerification"
DataTable.ImportSheet strDataPath & "CorporateActionsReports.xls
","HomePageVerification","HomePageVerification"
' Logs the Scenario name Execution in a .csv file
Call Execution_log(DataTable.Value("Scenario_Name", "Master"), "
", "", "")
'****Invoking IE and navigating to the ADR Login page
DataTable.GetSheet("CALogin").SetCurrentRow(1)
Call invoke_URL("CorporateActions","Login Page",DataTable.Value(
"URL","CALogin"))
'****Checking the username, password and login objects in the lo
gin page
Call pageCheck_WebEdit("CorporateActions","Login Page","username
;j_password","")
Call pageCheck_WebButton("CorporateActions","Login Page","Login"
,"")
'****Entering username and password and login into the masterfil
e application
Call login("CorporateActions","Login Page","User","CALogin")
Environment.Value("DATATABLE_ROW")=1
DataTable.GetSheet("UnderlyingSourceComparison").SetCurrentRow(E
nvironment.Value("DATATABLE_ROW"))
'***************************************** TC Driver Strat *****
**************************************************
For intTCCount = 1 to TC_COUNT
Environment.Value("Execution_Log") = "True"
Environment.Value("TestCase_Log") = "True"
If DataTable("TestRunFlag","UnderlyingSourceComparison")
="Y" Then ''If run flag is Y in test data table
Reporter.ReportEvent micDone,"######## BEGIN TES
T CASE - '" & DataTable("TestCaseID","UnderlyingSourceComparison") & "' ########
### ","Execution of Test Case '" & DataTable("TestCaseDesc","UnderlyingSourceCom
parison") & "' Started"
strFuncName = "CAReportsUSC_TC" & intTCCount & "
()" ''Formation of function name
''Call Function
Execute "Call " & strFuncName
If Environment.Value("Execution_Log") = "True"
Then
Call Execution_log("",Datatable.
Value("TestCaseID", "UnderlyingSourceComparison"), Datatable.Value("TestCaseDesc
", "UnderlyingSourceComparison"), "PASS")
Else
Call Execution_log("",Datatable.
Value("TestCaseID", "UnderlyingSourceComparison"), Datatable.Value("TestCaseDesc
", "UnderlyingSourceComparison"), "FAIL")
End If
Reporter.ReportEvent micDone,"######### END OF T
EST CASE - '" & DataTable("TestCaseID","UnderlyingSourceComparison") & "########
###","The Test Case Execution Completed"
End If

strPrevious=Trim(DataTable.Value("TestCaseID","Underlyin
gSourceComparison"))
''Increment the test data table row
Environment.Value("DATATABLE_ROW") = Environment.Value("
DATATABLE_ROW") + 1
DataTable.GetSheet("UnderlyingSourceComparison").SetCurr
entRow(Environment.Value("DATATABLE_ROW"))
strNext=Trim(DataTable.Value("TestCaseID","UnderlyingSou
rceComparison"))
While strPrevious = strNext
Environment.Value("DATATABLE_ROW") = Environment
.Value("DATATABLE_ROW") + 1
DataTable.GetSheet("UnderlyingSourceComparison")
.SetCurrentRow(Environment.Value("DATATABLE_ROW"))
strNext=Trim(DataTable.Value("TestCaseID","Under
lyingSourceComparison"))
Wend
Next
Call logoutfromApp("CorporateActions","Depositary Receipt Divisi
on's")
'***************************************** TC Driver End *******
************************************************

End Sub
'********************************************** Test Case 1 to Test Case 15 ****
**********************************************

Public Function CAReportsUSC_TC1()


' Check the Corporate Action Home Page for the 4 links, User Name and th
e last Login Details
Call chkADRHomePage("CorporateActions","Depositary Receipt Divis
ion's",DataTable.Value("HomePageLinks","HomePageVerification"),Environment.Value
("NormalUser"))
If Environment.Value("TestCase_Log") = "True"Then
Reporter.ReportEvent micPass,"Step 1: Check for
DR Home Page","The Required Links and the User Details are displayed Successfull
y"
Else
Reporter.ReportEvent micFail,"Step 1: Check for
DR Home Page","The Required Links and the User Details are NOT displayed Success
fully"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
' Clicking on the Corporate Action Element
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
' Check the Corporate Action Menus after clicking on the Corpora
te Actions link after clicking on Corporate Actions
Call chkMFCAHomePage("CorporateActions","CorporateActions",DataT
able.Value("MenuName","HomePageVerification"),Environment.Value("NormalUser"))
If Environment.Value("TestCase_Log") = "True"Then
Reporter.ReportEvent micPass,"Step 2: Click on Corporate
Action Element and Check for CA Home Page","The Required Menu Items are Display
ed Successfully"
Else
Reporter.ReportEvent micFail,"Step 2: Click on Corporate
Action Element and Check for CA Home Page","The Required Menu Items are Display
ed Successfully"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
' Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",10000
' Checks for the Web Edit present in the UnderlyingSourceCompari
son Home Page
Call pageCheck_WebEdit("CorporateActions","Reports - Underlying
Source Comparison Search Page","cactnEvntNm;cactnEvntDt;cactnTypeTx;isinNo","")
' Checks for the Web Elements present in the UnderlyingSourceCom
parison Home Page
Call pageCheck_WebElementinTable("CorporateActions","Reports - U
nderlying Source Comparison Search Page","Search Criteria:;Search Results;Source
;Sender BIC;Underlying Security;Corporate Action Type;ISIN","")
' Checks for the Images present in the UnderlyingSourceCompariso
n Home Page
Call pageCheck_Image("CorporateActions","Reports - Underlying So
urce Comparison Search Page","Search;Clear","")
'Checks for the Images Present next to the Web Edits UnderlyingS
ourceComparison Home Page
Call chkImageinUSCSearchPage("CorporateActions","Reports - Under
lying Source Comparison Search Page")
If Environment.Value("TestCase_Log") = "True"Then
Reporter.ReportEvent micPass,"Step 3: Ve
rifying if all the Required Elements or Fields are Present in the Screen","The R
equired Field are Present in the Reports Underlying Source Comparison Screen"
Else
Reporter.ReportEvent micFail,"Step 3: Ve
rifying if all the Required Elements or Fields are Present in the Screen","The R
equired Field are NOT Present in the Reports Underlying Source Comparison Screen
"
Environment.Value("Execution_Log") = "Fa
lse"
Environment.Value("TestCase_Log") = "Tru
e"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Page","Home;DR Home")
End Function

'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC2()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
blnFlag = Browser("CorporateActions").Page("Reports - Underlying
Source Comparison Search Page").Exist(1)
If blnFlag = "False" Then
Environment.Value("TestCase_Log") = "False"
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is Displayed"
Else
Reporter.ReportEvent micFail,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is NOT Displayed"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
strEventName = get_WebEdit_Value("CorporateActions","Reports - U
nderlying Source Comparison Search Page","EventName")
strEventDate = get_WebEdit_Value("CorporateActions","Reports - U
nderlying Source Comparison Search Page","EventDate")
strCAType = get_WebEdit_Value("CorporateActions","Reports - Unde
rlying Source Comparison Search Page","CorporateActionType")
strISIN = get_WebEdit_Value("CorporateActions","Reports - Underl
ying Source Comparison Search Page","ISIN")
If strEventName = "" AND strEventDate = "" AND strCAType ="" AND
strISIN = "" Then
Reporter.ReportEvent micPass,"Step 2: Verifying
the Default Values of the Field Present", "The Default Value of the Field Presen
t is NULL"
Else
Reporter.ReportEvent micFail,"Step 2: Verifying
the Default Values of the Field Present", "The Default Value of the Field Presen
t are NOT NULL"
Environment.Value("Execution_Log") = "False"
Call captureScreenShot()
End If
'Entering the Event Name as the Search Criteria , checking for S
earch Criteria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingS
ourceComparison"),"EventName")
'Logs the Status of the Test Case Execution in a .csv file
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 3, 4, 5 ,6: V
erifying the Results are Displayed according to the Search Criteria Entered","Th
e Results are Generated according to the Search Criteria Entered"
Else
Reporter.ReportEvent micFail,"Step 3, 4, 5 ,6: V
erifying the Results are Displayed according to the Search Criteria Entered","Th
e Results are NOT Generated according to the Search Criteria Entered"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++

Public Function CAReportsUSC_TC3()


Environment.Value("TestCase_Log") = "True"
Call click_WebElement("CorporateActions","Depositary Receipt Divisio
n's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
blnFlag = Browser("CorporateActions").Page("Reports - Underlying
Source Comparison Search Page").Exist(1)
If blnFlag = "False" Then
Environment.Value("TestCase_Log") = "False"
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is Displayed"
Else
Reporter.ReportEvent micFail,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is NOT Displayed"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
'Entering the Event Name as the Search Criteria , checking for S
earch Criteria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingS
ourceComparison"),"EventName")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 2,3,4,5,6: Ve
rifying the Selected Event Name, Checking for the Dispalyed Results for the Even
t Name and for the 4 Check boxes","The Required Details are Displayed successful
ly and the rest of the Check boxes are Disabled when 4 Notification are Selected
"
Else
Reporter.ReportEvent micFail,"Step 2,3,4,5,6: Ve
rifying the Selected Event Name, Checking for the Dispalyed Results for the Even
t Name and for the 4 Check boxes","The Required Details are NOT Displayed succes
sfully and the rest of the Check boxes are NOT Disabled when 4 Notification are
Selected"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Page","Home;DR Home")
End Function

'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC4()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
blnFlag = Browser("CorporateActions").Page("Reports - Underlying
Source Comparison Search Page").Exist(1)
If blnFlag = "False" Then
Environment.Value("TestCase_Log") = "False"
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is Displayed"
Else
Reporter.ReportEvent micFail,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is NOT Displayed"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If

' Entering the Event Date as the Search Criteria , checking for
Search Criteria and the Report Header
Wait(2)
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventNameinEventDate","
UnderlyingSourceComparison"),"EventDate")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 2,3,4,5,6,7:
Verifying the Selected Event Name, checking for the Search Criteria and the resp
ective Results ","The Results are Dispalyed according to the Search Criteria"
Else
Reporter.ReportEvent micFail,"Step 2,3,4,5,6,7:
Verifying the Selected Event Name, checking for the Search Criteria and the resp
ective Results ","The Results are NOT Dispalyed according to the Search Criteria
"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++

Public Function CAReportsUSC_TC5()


Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Division
's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
blnFlag = Browser("CorporateActions").Page("Reports - Underlying
Source Comparison Search Page").Exist(1)
If blnFlag = "False" Then
Environment.Value("TestCase_Log") = "False"
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is Displayed"
Else
Reporter.ReportEvent micFail,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is NOT Displayed"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
' Entering the Corporate Action Type as the Search Criteria , checking f
or Search Criteria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventNameinCorporateTyp
e","UnderlyingSourceComparison"),"CorporateActionType")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 2,3,4,5: Veri
fying the Selected Event Name, checking for the Search Criteria and the respecti
ve Results ","The Results are Dispalyed according to the Search Criteria"
Else
Reporter.ReportEvent micFail,"Step 2,3,4,5: Veri
fying the Selected Event Name, checking for the Search Criteria and the respecti
ve Results ","The Results are NOT Dispalyed according to the Search Criteria"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC6()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
blnFlag = Browser("CorporateActions").Page("Reports - Underlying
Source Comparison Search Page").Exist(1)
If blnFlag = "False" Then
Environment.Value("TestCase_Log") = "False"
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is Displayed"
Else
Reporter.ReportEvent micFail,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is NOT Displayed"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
' Entering the ISIN Details as the Search Criteria , checking for Search
Criteria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventNameinISIN","Under
lyingSourceComparison"),"ISIN")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 2,3,4,5: Veri
fying the Selected Event Name, checking for the Search Criteria and the respecti
ve Results ","The Results are Dispalyed according to the Search Criteria"
Else
Reporter.ReportEvent micFail,"Step 2,3,4,5
: Verifying the Selected Event Name, checking for the Search Criteria and the re
spective Results ","The Results are NOT Dispalyed according to the Search Criter
ia"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function

'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC7()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
blnFlag = Browser("CorporateActions").Page("Reports - Underlyin
g Source Comparison Search Page").Exist(1)
If blnFlag = "False" Then
Environment.Value("TestCase_Log") = "False"
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is Displayed"
Else
Reporter.ReportEvent micFail,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is NOT Displayed"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call USCchkReportsDetails("CorporateActions","Reports - Underlying Sou
rce Comparison Search Page",DataTable.Value("SelectEventNameinISIN","UnderlyingS
ourceComparison"),"ISIN")
If Environment.Value("TestCase_Log")= "True" Then
Reporter.ReportEvent micPass,"Step 2,3,4: Verify
ing the Data filled in the Fields in the UnderlyingSourceComparison","The Entere
d Values are Displayed successfully in the Page"
Else
Reporter.ReportEvent micFail,"Step 2,3,4: Verify
ing the Data filled in the Fields in the UnderlyingSourceComparison","The Entere
d Values are NOT Displayed successfully in the Page"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log")= "True"
End If
Call click_Image("CorporateActions","Reports - Underlying Source
Comparison Search Page","Clear")
Wait(5)
strEventName = get_WebEdit_Value("CorporateActions","Reports -
Underlying Source Comparison Search Page","EventName")
strEventDate = get_WebEdit_Value("CorporateActions","Reports - U
nderlying Source Comparison Search Page","EventDate")
strCAType = get_WebEdit_Value("CorporateActions","Reports - Unde
rlying Source Comparison Search Page","CorporateActionType")
strISIN = get_WebEdit_Value("CorporateActions","Reports - Underl
ying Source Comparison Search Page","ISIN")
If strEventName = "" AND strEventDate = "" AND strCAType ="" AND
strISIN = "" Then
Reporter.ReportEvent micPass,"Step 5: Verifying
if the Displayed Results are Cleared or NOT","The Displayed Results are Cleared"
Else
Reporter.ReportEvent micFail,"Step 5: Verifying
if the Displayed Results are Cleared or NOT","The Displayed Results are NOT Clea
red"
Environment.Value("Execution_Log")= "False"
Call captureScreenShot()
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Page","Home;DR Home")

End Function

'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++

Public Function CAReportsUSC_TC8()


Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
blnFlag = Browser("CorporateActions").Page("Reports - Underlyin
g Source Comparison Search Page").Exist(1)
If blnFlag = "False" Then
Environment.Value("TestCase_Log") = "False"
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is Displayed"
Else
Reporter.ReportEvent micFail,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is NOT Displayed"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call USCchkReportsDetails("CorporateActions","Reports - Underlying Sourc
e Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingSourceCom
parison"),"EventName")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 2,3,4,5: Veri
fying dispalyed Result and check for the Number of Notification","The Results ar
e Displayed based on the Search Criteria and the Number of Notification is great
er than or equal to 4"
Else
Reporter.ReportEvent micFail,"Step 2,3,4,5: Veri
fying dispalyed Result and check for the Number of Notification","The Results ar
e NOT Displayed based on the Search Criteria OR the Number of Notification is NO
T greater than or equal to 4"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call click_Image("CorporateActions","Reports - Underlying Source
Comparison Search Page","EventName_Icon")
blnClearFlag = Browser("CorporateActions").Page("Reports - Und
erlying Source Comparison Search Page").Frame("lookupFrame").Image("Clear Field
Value").Exist(1)
blnCalenderFlag = Browser("CorporateActions").Page("Reports -
Underlying Source Comparison Search Page").Frame("lookupFrame").Image("EventDate
_Calender").Exist(1)
blnGoFlag = Browser("CorporateActions").Page("Reports - Underl
ying Source Comparison Search Page").Frame("lookupFrame").Image("Go").Exist(1)
If blnClearFlag = "True" AND blnCalenderFlag = "True" AND bln
GoFlag = "True" Then
Environment.Value("TestCase_Log") = "True"
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 6: Verifying
the Fields present in the Pop up after clicking on the Info Image","The Required
Fields are Present in the Popup"
Else
Reporter.ReportEvent micFail,"Step 6: Verifying
the Fields present in the Pop up after clicking on the Info Image","The Required
Fields are NOT Present in the Popup"
Call captureScreenShot()
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
blnFlag = Browser("CorporateActions").Page("Reports - Underlyin
g Source Comparison Search Page").Frame("lookupFrame").Image("Clear Field Value"
).Exist(1)
If blnFlag = "True" Then
Browser("CorporateActions").Page("Reports - Unde
rlying Source Comparison Search Page").Frame("lookupFrame").Image("Clear Field V
alue").Click
Reporter.ReportEvent micPass,"Clicking on the Cl
ear Image","Clicked on Clear Image Successfully"
Else
Reporter.ReportEvent micFail,"Clicking on the Cl
ear Image","Not Able to Click on the Clear Image Successfully"
Environment.Value("Execution_Log") = "False"
Call captureScreenShot()
End If
strEventName = get_WebEdit_Value("CorporateActions","Reports - Underlyin
g Source Comparison Search Page","EventName")
strEventDate = get_WebEdit_Value("CorporateActions","Reports - U
nderlying Source Comparison Search Page","EventDate")
strCAType = get_WebEdit_Value("CorporateActions","Reports - Unde
rlying Source Comparison Search Page","CorporateActionType")
strISIN = get_WebEdit_Value("CorporateActions","Reports - Underl
ying Source Comparison Search Page","ISIN")
intRowCounter = Browser("CorporateActions").Page("Reports - Underlying S
ource Comparison Search Page").WebTable("Search Results").RowCount
If strEventName = "" AND strEventDate = "" AND strCAType = "" A
ND strISIN = "" AND intRowCounter <= 2 Then
Reporter.ReportEvent micPass,"Step 7: Verifying
the Fields after clicking on the Clear Icon in the Popup","The Values in the Fie
lds are Cleared"
Else
Reporter.ReportEvent micPass,"Step 7: Verifying
the Fields after clicking on the Clear Icon in the Popup","The Values in the Fie
lds are Cleared"
Environment.Value("Execution_Log")= "False"
Call captureScreenShot()
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Page","Home;DR Home")
End Function

'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++

Public Function CAReportsUSC_TC9()


Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
blnFlag = Browser("CorporateActions").Page("Reports - Underlyin
g Source Comparison Search Page").Exist(1)
If blnFlag = "False" Then
Environment.Value("TestCase_Log") = "False"
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is Displayed"
Else
Reporter.ReportEvent micFail,"Step 1: Verifying
the Reports Underlying Source Comparison page","The Page Reports Underlying Sou
rce Comparison is NOT Displayed"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call USCchkReportsDetails("CorporateActions","Reports - Underlying Sourc
e Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingSourceCom
parison"),"EventName")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 2,3,4,5,6: Ve
rifying dispalyed Result and check for the Number of Notification","The Results
are Displayed based on the Search Criteria and the Number of Notification is gre
ater than or equal to 4"
Else
Reporter.ReportEvent micFail,"Step 2,3,4,5,6: Ve
rifying dispalyed Result and check for the Number of Notification","The Results
are NOT Displayed based on the Search Criteria OR the Number of Notification is
NOT greater than or equal to 4"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
intRowCount = Browser("CorporateActions").Page("Reports - Under
lying Source Comparison Search Report").WebTable("Item").RowCount
intColCount = Browser("CorporateActions").Page("Reports - Under
lying Source Comparison Search Report").WebTable("Item").ColumnCount(1)
For intColCounter =1 to intColCount
strCellData = Browser("CorporateActions").Page("Reports
- Underlying Source Comparison Search Report").WebTable("Item").GetCellData(1,in
tColCounter)
If strCellData = "Field Name" Then
Browser("CorporateActions").Page("Reports - Unde
rlying Source Comparison Search Report").WebElement("html tag:=TH","innertext:=
" &strCellData).Click
Exit For
End If
Next
Call chkSortOrder("CorporateActions","Reports - Underlying Sourc
e Comparison Search Report","Item","Field Name","Ascending")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 7: Verifying
if the Field Name Field is Sorted in Ascending Order","The Fields are Sorted in
Ascending Order"
Else
Reporter.ReportEvent micFail,"Step 7: Verifying
if the Field Name Field is Sorted in Ascending Order","The Fields are NOT Sorted
in Ascending Order"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
intRowCount = Browser("CorporateActions").Page("Reports - Unde
rlying Source Comparison Search Report").WebTable("Item").RowCount
intColCount = Browser("CorporateActions").Page("Reports - Under
lying Source Comparison Search Report").WebTable("Item").ColumnCount(1)
For intColCounter =1 to intColCount
strCellData = Browser("CorporateActions").Page("Reports
- Underlying Source Comparison Search Report").WebTable("Item").GetCellData(1,in
tColCounter)
If strCellData = "Field Name" Then
Browser("CorporateActions").Page("Reports - Unde
rlying Source Comparison Search Report").WebElement("html tag:=TH","innertext:=
" &strCellData).Click
Exit For
End If
Next
Call chkSortOrder("CorporateActions","Reports - Underlying Sourc
e Comparison Search Report","Item","Field Name","Descending")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 8: Verifying
if the Field Name Field is Sorted in Descending Order","The Fields are Sorted in
Descending Order"
Else
Reporter.ReportEvent micFail,"Step 8: Verifying
if the Field Name Field is Sorted in Descending Order","The Fields are NOT Sorte
d in Descending Order"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC10()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
' Entering the ISIN Details as the Search Criteria , checking for Search
Criteria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventNameinISIN","Under
lyingSourceComparison"),"ISIN")
' Clickin on the Search Element to Naviagte back to the Underlyi
ng Source Comparison Search page
Call Click_WebElement("CorporateActions","Reports - Underlying S
ource Comparison Search Report","Search")
' Checking if the Underlying Source Comparison Search page is di
splayed or Not
If Browser("CorporateActions").Page("Reports - Underlying Source
Comparison Search Page").Exist(2) Then
Reporter.ReportEvent micPass,"Step 1: Verfying the Page
Dispalyed after Clicking on the Search Element","The Page 'Reports - Underlying
Source Comparison Search Page' is Displayed successfully after clicking on the S
earch Element"
Else
Reporter.ReportEvent micFail,"Step 1: Verfying the Page
Dispalyed after Clicking on the Search Element","The Page 'Reports - Underlying
Source Comparison Search Page' is NOT Displayed successfully after clicking on t
he Search Element"
Environment.Value("Execution_Log") = "False"
Environment.Value("Execution_Log") = "False"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Page","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC11()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
' Entering the ISIN Details as the Search Criteria , checking for Search
Criteria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventNameinISIN","Under
lyingSourceComparison"),"ISIN")
' Clicks on the Filter Element and fills the Filter Criteria
Call FilterCriteria("CorporateActions","Reports - Underlying Sou
rce Comparison Search Report","Filter",DataTable.Value("FilterColumn","Underlyin
gSourceComparison"),DataTable.Value("FilterExpression","UnderlyingSourceComparis
on"),DataTable.Value("FilterValue","UnderlyingSourceComparison"))
' Checking for the Filter Search Criteria
Call chkFilterSearchCriteria("CorporateActions","Reports - Under
lying Source Comparison Search Report",DataTable.Value("FilterColumn","Underlyin
gSourceComparison"),DataTable.Value("FilterExpression","UnderlyingSourceComparis
on"),DataTable.Value("FilterValue","UnderlyingSourceComparison"))
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1, 2: Verifyi
ng the Fields present in the Filter Table and checking for the Filter Search Cri
teria", "The Required fields are present in the Filter Table and also the Filter
Criteria is dispalyed as required"
Else
Reporter.ReportEvent micFail,"Step 1, 2: Verifyi
ng the Fields present in the Filter Table and checking for the Filter Search Cri
teria", "The Required fields and the Filter Criteria are NOT Dispalyed as requir
ed"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC12()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
'Entering the Event Name as the Search Criteria , checking for Search Crit
eria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingS
ourceComparison"),"EventName")
Call MultipleFilterCriteria("CorporateActions","Reports - Underlying Sou
rce Comparison Search Report",DataTable.Value("FilterColumn","UnderlyingSourceCo
mparison"),DataTable.Value("FilterExpression","UnderlyingSourceComparison"),Data
Table.Value("FilterValue","UnderlyingSourceComparison"),DataTable.Value("FilterC
ondition","UnderlyingSourceComparison"))
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1,2,3,4,5: Ve
rifying the Filter functionality","The Fields are Filtered according to the Filt
er Criteria and the Filter Creiteria is Dispalyed as per the entered Filter Crit
eria"
Else
Reporter.ReportEvent micFail,"Step 1,2,3,4,5: Ve
rifying the Filter functionality","The Fields are NOT Filtered according to the
Filter Criteria"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function

'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC13()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
'Entering the Event Name as the Search Criteria , checking for Search Crit
eria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingS
ourceComparison"),"EventName")
' Clicks on the Sort Element and fills the Sort Criteria
Call SortCriteria("CorporateActions","Reports - Underlying Sourc
e Comparison Search Report","Sort",DataTable.Value("SortColumn","UnderlyingSourc
eComparison"),DataTable.Value("SortOrder","UnderlyingSourceComparison"))
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1,2: Verifyin
g the Sort functionality","The Fields are Sorted according to the Sorted Criteri
a"
Else
Reporter.ReportEvent micFail,"Step 1,2: Verifyin
g the Sort functionality","The Fields are NOT Sorted according to the Sorted Cri
teria"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function

'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC14()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
'Entering the Event Name as the Search Criteria , checking for Search Crit
eria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingS
ourceComparison"),"EventName")
' Clicks on the Sort Element and fills the Sort Criteria
Call MultipleSortCriteria("CorporateActions","Reports - Underlying Sourc
e Comparison Search Report","Sort",DataTable.Value("SortColumn","UnderlyingSourc
eComparison"),DataTable.Value("SortOrder","UnderlyingSourceComparison"))
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1,2,3,4,5: Ve
rifying the Sort functionality by entering the Sort Criteria by clicking on Add
button","The Fields are Sorted according to the Sorted Criteria"
Else
Reporter.ReportEvent micFail,"Step 1,2,3,4,5: Ve
rifying the Sort functionality by entering the Sort Criteria by clicking on Add
button","The Fields are NOT Sorted according to the Sorted Criteria"
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "True"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function

'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++
Public Function CAReportsUSC_TC15()
Environment.Value("TestCase_Log") = "True"
'Selecting the UnderlyingSourceComparison Sub Menu from Reports
Menu and Waits for the Search Image to be Visible
Call click_WebElement("CorporateActions","Depositary Receipt Div
ision's","CorporateActions")
Call Select_Menu("CorporateActions","CorporateActions",DataTable
.Value("MenuPath","UnderlyingSourceComparison"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
'Entering the Event Name as the Search Criteria , checking for S
earch Criteria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingS
ourceComparison"),"EventName")
Wait(5)
var_X = Browser("CorporateActions").Page("Reports - Underlying S
ource Comparison Search Report").WebElement("SaveAsExcel").GetROProperty("x")
var_Y = Browser("CorporateActions").Page("Reports - Underlying S
ource Comparison Search Report").WebElement("SaveAsExcel").GetROProperty("y")
Window("regexpwndtitle:=Microsoft Internet Explorer", "regexpwnd
class:=IEFrame").WinObject("regexpwndclass:=Internet Explorer_Server").Click var
_X+10, var_Y+10
Wait(10)
If Dialog("text:=File Download").Exist(2) Then
blnSaveFlag = Dialog("text:=File Download").WinB
utton("text:=&Save").Exist(1)
blnOpenFlag = Dialog("text:=File Download").WinB
utton("text:=&Open").Exist(1)
blnCancelFlag = Dialog("text:=File Download").Wi
nButton("text:=Cancel").Exist(1)
If blnSaveFlag = "True" AND blnOpenFlag ="True"
AND blnCancelFlag = "True" Then
Reporter.ReportEvent micPass,"Step 1: Ve
rifying for the Dialog and respective buttons","The Dialog is displayed with Sav
e, Open and Cancel button"
Else
Reporter.ReportEvent micFail,"Step 1: Ve
rifying for the Dialog and respective buttons","The Dialog is NOT displayed with
Save, Open and Cancel button"
Call captureScreenShot()
Environment.Value("TestCase_Log") = "Fal
se"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micFail,"Step 1: Verifying
if the Save Dialog is Displayed or NOT","The Save Dialog is NOT displayed"
Call captureScreenShot()
Environment.Value("TestCase_Log") = "False"
Environment.Value("Execution_Log") = "False"
End If
' Clicking on Save As Excel and Opening the Excel Sheet
Call SaveASExcel_USC("CorporateActions","Reports - Underlying So
urce Comparison Search Report","UnderlyingSourceComparison","Open")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 2: Verifying
if the Excel Sheet is Opened Successfully","The Excel Sheet is Opened Successful
ly dispalying the Result details"
Else
Reporter.ReportEvent micFail,"Step 2: Verifying
if the Excel Sheet is Opened Successfully","The Excel Sheet is NOT Opened Succe
ssfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call Click_WebElement("CorporateActions","Reports - Underlying S
ource Comparison Search Report","Search")
'Call Select_Menu("CorporateActions","Reports - Underlying Sourc
e Comparison Search Report",DataTable.Value("MenuPath","UnderlyingSourceComparis
on"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
'Entering the Event Name as the Search Criteria , checking for S
earch Criteria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingS
ourceComparison"),"EventName")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 3: Verifying
the generated Report Result","The Report is generated as per the Search Criteria
"
Else
Reporter.ReportEvent micFail,"Step 3: Verifying
the generated Report Result","The Report is NOT generated as per the Search Crit
eria"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
var_X = Browser("CorporateActions").Page("Reports - Underlying S
ource Comparison Search Report").WebElement("SaveAsExcel").GetROProperty("x")
var_Y = Browser("CorporateActions").Page("Reports - Underlying S
ource Comparison Search Report").WebElement("SaveAsExcel").GetROProperty("y")
Window("regexpwndtitle:=Microsoft Internet Explorer", "regexpwnd
class:=IEFrame").WinObject("regexpwndclass:=Internet Explorer_Server").Click var
_X+10, var_Y+10
If Dialog("text:=File Download").Exist(2) Then
blnSaveFlag = Dialog("text:=File Download").WinB
utton("text:=&Save").Exist(1)
blnOpenFlag = Dialog("text:=File Download").WinB
utton("text:=&Open").Exist(1)
blnCancelFlag = Dialog("text:=File Download").Wi
nButton("text:=Cancel").Exist(1)
If blnSaveFlag = "True" AND blnOpenFlag ="True"
AND blnCancelFlag = "True" Then
Reporter.ReportEvent micPass,"Step 4: Ve
rifying for the Dialog and respective buttons","The Dialog is displayed with Sav
e, Open and Cancel button"
Else
Reporter.ReportEvent micFail,"Step 4: Ve
rifying for the Dialog and respective buttons","The Dialog is NOT displayed with
Save, Open and Cancel button"
Call captureScreenShot()
Environment.Value("TestCase_Log") = "Fal
se"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micFail,"Step 4: Verifying
if the Save Dialog is Displayed or NOT","The Save Dialog is NOT displayed"
Call captureScreenShot()
Environment.Value("TestCase_Log") = "False"
Environment.Value("Execution_Log") = "False"
End If
' Clicking on the Field Name field for Sorting
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Report").WebElement("html tag:=TH","innertext:=Field Name").Clic
k
' Saving the Result in a Excel sheet.
Call SaveASExcel("CorporateActions","Reports - Underlying Source
Comparison Search Report","UnderlyingSourceComparison","Save")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 5: Verifying
if the File is Saved Successfully or Not","The File is saved Successfully"
Else
Reporter.ReportEvent micFail,"Step 5: Verifying
if the File is Saved Successfully or Not","The File is NOT saved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call Click_WebElement("CorporateActions","Reports - Underlying S
ource Comparison Search Report","Search")
'Call Select_Menu("CorporateActions","Reports - Underlying Sourc
e Comparison Search Report",DataTable.Value("MenuPath","UnderlyingSourceComparis
on"))
Browser("CorporateActions").Page("Reports - Underlying Source Co
mparison Search Page").Image("Search").WaitProperty "Visible","True",100000
'Entering the Event Name as the Search Criteria , checking for S
earch Criteria and the Report Header
Call USCchkReportsDetails("CorporateActions","Reports - Underlyi
ng Source Comparison Search Page",DataTable.Value("SelectEventName","UnderlyingS
ourceComparison"),"EventName")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 6: Verifying
the generated Report Result","The Report is generated as per the Search Criteria
"
Else
Reporter.ReportEvent micFail,"Step 6: Verifying
the generated Report Result","The Report is NOT generated as per the Search Crit
eria"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
var_X = Browser("CorporateActions").Page("Reports - Underlying S
ource Comparison Search Report").WebElement("SaveAsExcel").GetROProperty("x")
var_Y = Browser("CorporateActions").Page("Reports - Underlying S
ource Comparison Search Report").WebElement("SaveAsExcel").GetROProperty("y")
Window("regexpwndtitle:=Microsoft Internet Explorer", "regexpwnd
class:=IEFrame").WinObject("regexpwndclass:=Internet Explorer_Server").Click var
_X+10, var_Y+10
If Dialog("text:=File Download").Exist(2) Then
blnSaveFlag = Dialog("text:=File Download").WinB
utton("text:=&Save").Exist(1)
blnOpenFlag = Dialog("text:=File Download").WinB
utton("text:=&Open").Exist(1)
blnCancelFlag = Dialog("text:=File Download").Wi
nButton("text:=Cancel").Exist(1)
If blnSaveFlag = "True" AND blnOpenFlag ="True"
AND blnCancelFlag = "True" Then
Reporter.ReportEvent micPass,"Step 7: Ve
rifying for the Dialog and respective buttons","The Dialog is displayed with Sav
e, Open and Cancel button"
Else
Reporter.ReportEvent micFail,"Step 7: Ve
rifying for the Dialog and respective buttons","The Dialog is NOT displayed with
Save, Open and Cancel button"
Call captureScreenShot()
Environment.Value("TestCase_Log") = "Fal
se"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micFail,"Step 7: Verifying
if the Save Dialog is Displayed or NOT","The Save Dialog is NOT displayed"
Call captureScreenShot()
Environment.Value("TestCase_Log") = "False"
Environment.Value("Execution_Log") = "False"
End If
' Saving the Result in a Excel sheet.
Call SaveASExcel("CorporateActions","Reports - Underlying Source
Comparison Search Report","UnderlyingSourceComparison","Cancel")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 8: Verifying
if the Save Dialog is Closed or NOT","The Saved Dialog is Closed Successfully"
Else
Reporter.ReportEvent micFail,"Step 8: Verifying
if the Save Dialog is Closed or NOT","The Saved Dialog is NOT Closed Successfull
y"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call Select_Menu("CorporateActions","Reports - Underlying Source
Comparison Search Report","Home;DR Home")
End Function

'++++++++++++++++++++++++++++++++++++++++++++ Test Case Ends ++++++++++++++++++


++++++++++++++++++++++++++++++++++

Você também pode gostar