Professional Documents
Culture Documents
==========================
' Name of the Script : DR Life Cycle
' Scope of the Script : This test script covers 29 te
st cases related to the DRLifeCycle
' Author : Shyam H D
' Description : DR Life Cycle
' Date and / or Version : 05-01-2009,version 1.0
'===============================================================================
============================
'Sub DRLifeCycle()
Public Function DRLifeCycle()
'****Declaration of Environmental Variable
Environment.Value("Execution_Log") = "True"
Environment.Value("TestCase_Log") = "True"
Environment.Value("AppURL") = "https://160.254.95.16:9123/adr/lo
gin.page"
'''''''''Test case count
Const TC_COUNT = 29
strVar = Environment("TestDir")
strIndVar = Split(strVar,"\",-1,1)
strBound = UBound(strIndVar)
strAllPath =""
For intCounter = 0 to strBound - 1
strAllPath = strAllPath & strIndVar(intCounter)
&"\"
Next
strPath = Trim(strPath)
strDataPath = strAllPath & "DataTables\"
strLibPath = strAllPath & "Function_Library\"
'****Adding MFLogin sheet to the dataTable and Importing the Input DataT
able
DataTable.AddSheet "MFLogin"
DataTable.ImportSheet strDataPath & "Login.xls","MFLogin","MFLog
in"
DataTable.AddSheet "DRLifeCycle"
DataTable.ImportSheet strDataPath & "DRLifeCycle.xls","DRLifeCyc
le","DRLifeCycle"
DataTable.AddSheet "ReportHeader"
DataTable.ImportSheet strDataPath & "MasterFileProfile.xls","Rep
ortHeader","ReportHeader"
DataTable.AddSheet "HomePageVerification"
DataTable.ImportSheet strDataPath & "MasterFileProfile.xls","Hom
ePageVerification","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
'Call invoke_URL("MasterFile","Login Page",DataTable.Value("URL"
,"MFLogin"))
'****Checking the username, password and login objects in the lo
gin page
'Call pageCheck_WebEdit("MasterFile","Login Page","username;j_pa
ssword","")
'Call pageCheck_WebButton("MasterFile","Login Page","Login","")
'****Entering username and password and login into the masterfil
e application
'Call login("MasterFile","Login Page","User","MFLogin")
Environment.Value("DATATABLE_ROW")=1
DataTable.GetSheet("DRLifeCycle").SetCurrentRow(Environment.Valu
e("DATATABLE_ROW"))
'***************************************** TC Driver Strat *****
**************************************************
For intTCCount = 1 to TC_COUNT
Environment.Value("Execution_Log") = "True"
If DataTable("TestRunFlag","DRLifeCycle")="Y" Then
''If run flag is Y in test data table
Reporter.ReportEvent micDone,"######## BEGIN TES
T CASE - '" & DataTable("TestCaseID","DRLifeCycle") & "' ########### ","Executio
n of Test Case '" & DataTable("TestCaseDesc","DRLifeCycle") & "' Started"
strFuncName = "DRLifeCycle_TC" & intTCCount & "(
)" ''Formation of function name
'MsgBox strFuncName
''Call Function
Execute "Call " & strFuncName
If Environment.Value("Execution_Log") = "True"
Then
Call Execution_log("",Datatable.
Value("TestCaseID", "DRLifeCycle"), Datatable.Value("TestCaseDesc", "DRLifeCycle
"), "PASS")
Else
Call Execution_log("",Datatable.
Value("TestCaseID", "DRLifeCycle"), Datatable.Value("TestCaseDesc", "DRLifeCycle
"), "FAIL")
End If
Reporter.ReportEvent micDone,"######### END OF T
EST CASE - '" & DataTable("TestCaseID","DRLifeCycle") & "###########","The Test
Case Execution Completed"
End If
strPrevious=Trim(DataTable.Value("TestCaseID","DRLifeCyc
le"))
''Increment the test data table row
Environment.Value("DATATABLE_ROW") = Environment.Value("
DATATABLE_ROW") + 1
DataTable.GetSheet("DRLifeCycle").SetCurrentRow(Environm
ent.Value("DATATABLE_ROW"))
strNext=Trim(DataTable.Value("TestCaseID","DRLifeCycle")
)
While strPrevious = strNext
Environment.Value("DATATABLE_ROW") = Environment
.Value("DATATABLE_ROW") + 1
DataTable.GetSheet("DRLifeCycle").SetCurrentRow(
Environment.Value("DATATABLE_ROW"))
strNext=Trim(DataTable.Value("TestCaseID","DRLif
eCycle"))
Wend
Next
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
'***************************************** TC Driver End *******
************************************************
End Function
'End Sub
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++
Public Function DRLifeCycle_TC1()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to Step 42: Verifyi
ng if the DR is Upgraded successfully","The DR " & DataTable.Value("DRName","DRL
ifeCycle") & " is successfully Changed to Level " & DataTable.Value("UpgradeLeve
l","DRLifeCycle")
Else
Reporter.ReportEvent micFail,"Step 1 to Step 42: Verifyi
ng if the DR is Upgraded successfully","The DR " & DataTable.Value("DRName","DRL
ifeCycle") & " is NOT successfully Changed to Level " & DataTable.Value("Upgrade
Level","DRLifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 43 to 61: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 43 to 61: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 62 to 74: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Verfiying if the Modifed F
ields are Approved and check for the Flags","The Modifeid Fields are NOT Approve
d and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++
' Create a DR of Level I of BNY Depository and Sponsored DR
'======== Upgrade from Level I to Level III
Public Function DRLifeCycle_TC2()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 42: Verifying if
the DR is Upgraded successfully","The DR " & DataTable.Value("DRName","DRLifeCy
cle") & " is successfully Changed to Level " & DataTable.Value("UpgradeLevel","D
RLifeCycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 42: Verifying if
the DR is Upgraded successfully","The DR " & DataTable.Value("DRName","DRLifeCy
cle") & " is NOT successfully Changed to Level " & DataTable.Value("UpgradeLevel
","DRLifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 43 to 61: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 43 to 61: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 62 to 74: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 62 to 74: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++
' Create a DR of Reg.S Type of Sponsored DR
'================ PPC DR from Reg.S to Level I
Public Function DRLifeCycle_TC3()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 20: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is successfully Changed to Level " & DataTable.Value("UpgradeLevel","DRLife
Cycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 20: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is NOT successfully Changed to Level " & DataTable.Value("UpgradeLevel","DR
LifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 21 to 34: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 21 to 34 :Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 35 to 46: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 35 to 46: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++
' Create a DR of 144A Type of Sponsored DR
'================ PPC DR from Reg.S to Level II
Public Function DRLifeCycle_TC4()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 42: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is successfully Changed to Level " & DataTable.Value("UpgradeLevel","DRLife
Cycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 42: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is NOT successfully Changed to Level " & DataTable.Value("UpgradeLevel","DR
LifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 43 to 66: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 43 to 66: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 67 to 78: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 67 to 78: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++
' Create a Bifurcated DR: Reg.S Sponsored DR
' =================== PPC Bifurcated DR to Level III
Public Function DRLifeCycle_TC5()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 20: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is successfully Changed to Level " & DataTable.Value("UpgradeLevel","DRLife
Cycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 20: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is NOT successfully Changed to Level " & DataTable.Value("UpgradeLevel","DR
LifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 21 to 34: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micPass,"Step 21 to 34: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 35 to 49: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 35 to 49: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++
' Need some Information from Manual Team
' Create a Level III DR of Sponsored Type
' ============== Delisting from Level III to Level I
Public Function DRLifeCycle_TC6()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 32Verifying if t
he DR is Delisting successfully","The DR " & DataTable.Value("DRName","DRLifeCyc
le") & " is successfully Changed to Level " & DataTable.Value("UpgradeLevel","DR
LifeCycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 32: Verifying if
the DR is Delisting successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is NOT successfully Changed to Level " & DataTable.Value("UpgradeLeve
l","DRLifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 33 to 51: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 33 to 51: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 52 to 64: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 52 to 64: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++
' Create a Level IIIDR of Sponsored Type
' ============== Delisting from Level II to Level I
Public Function DRLifeCycle_TC7()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 41: Veri
fying if the DR is Delisted successfully","The DR " & DataTable.Value("DRName","
DRLifeCycle") & " is successfully Changed to Level " & DataTable.Value("UpgradeL
evel","DRLifeCycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 41: Verifying if
the DR is Delisted successfully","The DR " & DataTable.Value("DRName","DRLifeCy
cle") & " is NOT successfully Changed to Level " & DataTable.Value("UpgradeLevel
","DRLifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 42 to 65: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 42 to 65: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 66 to 77: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 66 to 77: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++
' Create a DR of 144A of Sponsored DR
' '======================== PPC DR from 144A to Level I
Public Function DRLifeCycle_TC8()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 40: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is successfully Changed to Level " & DataTable.Value("UpgradeLevel","DRLife
Cycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 40: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is NOT successfully Changed to Level " & DataTable.Value("UpgradeLevel","DR
LifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 41 to 64: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 41 to 64: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 65 to 76: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 65 to 76: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++
' Create a DR of 144A of Sponsored DR
' '======================== PPC DR from 144A to Level II
Public Function DRLifeCycle_TC9()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 41: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is successfully Changed to Level " & DataTable.Value("UpgradeLevel","DRLife
Cycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 41: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is NOT successfully Changed to Level " & DataTable.Value("UpgradeLevel","DR
LifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 42 to 65: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micPass,"Step 42 to 65: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 66 to 76: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 66 to 76: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++
' Create a DR of 144A of Sponsored DR
' '======================== PPC DR from 144A to Level III of Sponsored Type
Public Function DRLifeCycle_TC10()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 43: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is successfully Changed to Level " & DataTable.Value("UpgradeLevel","DRLife
Cycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 43: Verifying if
the DR is PPC successfully","The DR " & DataTable.Value("DRName","DRLifeCycle")
& " is NOT successfully Changed to Level " & DataTable.Value("UpgradeLevel","DR
LifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 44 to 68: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 44 to 68: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 69 to 80: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 69 to 80: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
' Create a DR of Level I of Unsponsored DR
'===== Convert it to Sponsored Type DR with BNY Depository
Public Function DRLifeCycle_TC11()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 44: Verifying if
the DR is Converted successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is successfully Converted to Sponsored DR"
Else
Reporter.ReportEvent micPass,"Step 1 to 44: Verifying if
the DR is Converted successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is successfully NOT Converted to Unsponsored DR"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 45 to 63: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 45 to 63: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 64 to 76: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 64 to 76: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++
' Create a DR of Level II of Unsponsored DR
'===== Convert it to Sponsored Type DR with BNY Depository
Public Function DRLifeCycle_TC12()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 44: Verifying if
the DR is Converted successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is successfully Converted to Sponsored DR"
Else
Reporter.ReportEvent micFail,"Step 1 to 44: Verifying if
the DR is Converted successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is successfully NOT Converted to Sponsored DR"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 45 to 63: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 45 to 63: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 64 to 76: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 64 to 76: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
' Create a DR of Level III of Unsponsored DR
'===== Convert it to Sponsored Type DR with BNY Depository
Public Function DRLifeCycle_TC13()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 44: Verifying if
the DR is Converted successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is successfully Converted to Sponsored DR"
Else
Reporter.ReportEvent micFail,"Step 1 to 44: Verifying if
the DR is Converted successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is successfully NOT Converted to Sponsored DR"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 45 to 63: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 45 to 63: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 64 to 77: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 64 to 77: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
' Create a DR 144A First and then Reg.S both Sharing the Same CUSIP of "Unspons
ored Type"
' ============= Convert Bifurcated DR of Unsponsored to Sponsored with BNY Depos
itory
Public Function DRLifeCycle_TC14()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 44: Verifying if
the Bifurcated DR is Converrted successfully","The DR " & DataTable.Value("DRNa
me","DRLifeCycle") & " is successfully Converted to Sponsored DR"
Else
Reporter.ReportEvent micFail,"Step 1 to 44: Verifying if
the Bifurcated DR is Converted successfully","The DR " & DataTable.Value("DRNam
e","DRLifeCycle") & " is successfully NOT Converted to Sponsored DR"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 45 to 68: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 45 to 68: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 69 to 85: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 69 to 85: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
' Create a DR 144A First and then Reg.S both Sharing the Same CUSIP .
' ============= PPC for Bifurcated Reg.S DR
Public Function DRLifeCycle_TC15()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 46: Verifying if
the Bifurcated RegS DR is PPC successfully","The DR " & DataTable.Value("DRName
","DRLifeCycle") & " is successfully PPC to Level " & DataTable.Value("UpgradeLe
vel","DRLifeCycle")
Else
Reporter.ReportEvent micFail,"Step 1 to 46: Verifying if
the Bifurcated RegS DR is PPC successfull","The DR " & DataTable.Value("DRName"
,"DRLifeCycle") & " is NOT successfully PPC to Level " & DataTable.Value("Upgra
deLevel","DRLifeCycle")
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 47 to 70: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 47 to 70: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 71 to 86: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 71 to 86: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
' Create a Level II Dr of Sponsored Type
' ============ Warrent Level II DR
Public Function DRLifeCycle_TC16()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 33: Verifying if
the DR is Warrented successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is successfully Warrented"
Else
Reporter.ReportEvent micFail,"Step 1 to 33: Verifying if
the DR is Warrented successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is NOT successfully Warrented"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 34 to 52: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 34 to 52: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 53 to 62: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 53 to 62: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++++++
' Create a Level III DR of Sponsored Type
' ============ Warrent Level III DR
Public Function DRLifeCycle_TC17()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 24: Verifying if
the DR is Warrented successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is successfully Warrent"
Else
Reporter.ReportEvent micFail,"Step 1 to 24: Verifying if
the DR is Warrented successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is NOT Warrent successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 25 to 38: Approving
the Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 25 to 38: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 39 to 47: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 39 to 47: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++++
' Create 3 Un Sponsored DRs with different Depositary
Public Function DRLifeCycle_TC19()
For intTestCounter = 1 to 2
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" T
hen
Call CreateBifurcatedDR("MasterFile","Profile -
DR Search","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Sear
ch","DR Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR fo
r Performing DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRT
ype","DRLifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR
for Performing DR Life Cycle","The Required DR of type " & DataTable.Value("New
DRType","DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Login to the Application and Performing Corporate Acti
on on the DR
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call DR_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " Succe
ssfully"
Else
Reporter.ReportEvent micFail,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Not Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " S
uccessfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Underlying Security Pro
file")
'Loging with Approval ID and Approve the Changes made
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
' Approving the Changes
Call DRApprovalFunction_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 39 to 64: App
roving the Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 39 to 64: App
roving the Changes made to the DR","The Changes made are NOT Approved Successful
ly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Depositary Receipt Divi
sion's")
' Login again
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call click_WebElement("MasterFile","Depositary Receipt Divisi
on's","MasterFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("M
enuPath","DRLifeCycle"))
strStatus = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("Status").GetROProperty("value")
strDRType = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("DRType").GetROProperty("value")
strDROrigin = Browser("MasterFile").Page("Profile - DR S
earch").WebList("DROrigin").GetROProperty("value")
strCountryofManagement = Browser("MasterFile").Page("Pro
file - DR Search").WebList("CountryofManagement").GetROProperty("value")
SU = Browser("MasterFile").Page("Profile - DR Search").W
ebList("SU").GetROProperty("value")
strSubstatus = Browser("MasterFile").Page("Profile - DR
Search").WebList("SubStatus").GetROProperty("value")
strDRExchange = Browser("MasterFile").Page("Profile - DR
Search").WebList("DRExchange").GetROProperty("value")
If Instr(1,strStatus,"All") <> 0 And Instr(1,strDRType,"
All") <> 0 And Instr(1,strDROrigin,"All") <> 0 And Instr(1,strCountryofManagemen
t,"All") <> 0 And Instr(1,SU,"All") <> 0 And Instr(1,strSubstatus,"All") <> 0 An
d Instr(1,strDRExchange,"All") <> 0 Then
'If strStatus = " All" And strDRType = " All" And strDRO
rigin = " All" And strCountryofManagement = " All" And SU = " All" And strSubsta
tus = " All" And strDRExchange = " All" Then
Reporter.ReportEvent micPass,"Step 65 to 66: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields are 'All' "
Else
Reporter.ReportEvent micFail,"Step 65 to 66: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields areNOT 'All' "
Environment.Value("Execution_Log") = "False"
End If
'Search for the Modified DR
Call ModifiedDRSearchCriteria("MasterFile","Profile - DR Sear
ch","Search")
intValues = Browser("MasterFile").Page("Profile - DR Search").WebTabl
e("DRSearchResults").GetRowWithCellText(DataTable.Value("DRName","DRLifeCycle"))
If intValues <> -1 Then
Reporter.ReportEvent micPass,"Step 67: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is displayed in the Search Result"
Else
Reporter.ReportEvent micFail,"Step 67: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is NOT displayed in the Search Result"
Environment.Value("Execution_Log") = "False"
End If
' Selecting the Required DR
Browser("MasterFile").Page("Profile - DR Search").WebEle
ment("html tag:=TD","innertext:="& DataTable.Value("NewValue","DRLifeCycle")).Cl
ick
Wait(5)
'Comparing the Old Values in the Audit log
Call CompareDROldNewValue("MasterFile","DR Profile","2")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 69: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are Displayed Correctly"
Else
Reporter.ReportEvent micFail,"Step 69: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are NOt Displayed Correctly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Checks if the Flags are Present or Not
Call DRFlagCheck()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 68, 70 to 76:
Verifying if Pending Approval Flags are Still present after Approving the Chang
es made","The Pending Approval Flags are Not Present Next to the Modifed Fields
after approving the Changes made"
Else
Reporter.ReportEvent micFail,"Step 68, 70 to 76:
Verifying if Pending Approval Flags are Still present after Approving the Chang
es made","The Pending Approval Flags are Still Present Next to the Modifed Field
s after approving the Changes made"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Logout from Application and Approver the Changes made
to the Approver
Call logoutfromApp("MasterFile","Corporate Action Data F
ix")
' Loging with Approval ID and Approve the Changes made to
the Issuer
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
Call ApprovalFunction_DR("MasterFile","Underlying Securi
ty","Name;Status;Last User Updated;Last Updated",Environment.Value("UnderlyingSe
curityName"),"Approved","Approved","Pending Approval")
'IssuerName_NewValue
If intTestCounter <> 2 Then
Environment.Value("DATATABLE_ROW")= Environment.
Value("DATATABLE_ROW") + 1
DataTable.GetSheet("DRLifeCycle").SetCurrentRow(
Environment.Value("DATATABLE_ROW"))
End If
Next
Call select_Menu("MasterFile","Corporate Action Data Fix","Home;DR Home"
)
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++++
' Create Bifurcated Sponsored DRs -- Execute for 144 A and Reg.s
'================ Perform Corporate for DR 144 A and Then for Reg.S
Public Function DRLifeCycle_TC20()
For intTestCounter = 1 to 2
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" T
hen
Call CreateBifurcatedDR("MasterFile","Profile -
DR Search","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Sear
ch","DR Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR fo
r Performing DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRT
ype","DRLifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR
for Performing DR Life Cycle","The Required DR of type " & DataTable.Value("New
DRType","DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Login to the Application and Performing Corporate Acti
on on the DR
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call DR_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " Succe
ssfully"
Else
Reporter.ReportEvent micFail,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Not Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " S
uccessfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Underlying Security Pro
file")
'Loging with Approval ID and Approve the Changes made
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
' Approving the Changes
Call DRApprovalFunction_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 39 to 52: App
roving the Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 39 to 52: App
roving the Changes made to the DR","The Changes made are NOT Approved Successful
ly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Depositary Receipt Divi
sion's")
' Login again
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call click_WebElement("MasterFile","Depositary Receipt Divisi
on's","MasterFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("M
enuPath","DRLifeCycle"))
strStatus = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("Status").GetROProperty("value")
strDRType = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("DRType").GetROProperty("value")
strDROrigin = Browser("MasterFile").Page("Profile - DR S
earch").WebList("DROrigin").GetROProperty("value")
strCountryofManagement = Browser("MasterFile").Page("Pro
file - DR Search").WebList("CountryofManagement").GetROProperty("value")
SU = Browser("MasterFile").Page("Profile - DR Search").W
ebList("SU").GetROProperty("value")
strSubstatus = Browser("MasterFile").Page("Profile - DR
Search").WebList("SubStatus").GetROProperty("value")
strDRExchange = Browser("MasterFile").Page("Profile - DR
Search").WebList("DRExchange").GetROProperty("value")
If Instr(1,strStatus,"All") <> 0 And Instr(1,strDRType,"
All") <> 0 And Instr(1,strDROrigin,"All") <> 0 And Instr(1,strCountryofManagemen
t,"All") <> 0 And Instr(1,SU,"All") <> 0 And Instr(1,strSubstatus,"All") <> 0 An
d Instr(1,strDRExchange,"All") <> 0 Then
'If strStatus = " All" And strDRType = " All" And strDRO
rigin = " All" And strCountryofManagement = " All" And SU = " All" And strSubsta
tus = " All" And strDRExchange = " All" Then
Reporter.ReportEvent micPass,"Step 53 to 54: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields are 'All' "
Else
Reporter.ReportEvent micFail,"Step 53 to 54: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields areNOT 'All' "
Environment.Value("Execution_Log") = "False"
End If
'Search for the Modified DR
Call ModifiedDRSearchCriteria("MasterFile","Profile - DR Sear
ch","Search")
intValues = Browser("MasterFile").Page("Profile - DR Search").WebTabl
e("DRSearchResults").GetRowWithCellText(DataTable.Value("DRName","DRLifeCycle"))
If intValues <> -1 Then
Reporter.ReportEvent micPass,"Step 55: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is displayed in the Search Result"
Else
Reporter.ReportEvent micFail,"Step 55: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is NOT displayed in the Search Result"
Environment.Value("Execution_Log") = "False"
End If
' Selecting the Required DR
Browser("MasterFile").Page("Profile - DR Search").WebEle
ment("html tag:=TD","innertext:="& DataTable.Value("NewValue","DRLifeCycle")).Cl
ick
Wait(5)
'Comparing the Old Values in the Audit log
Call CompareDROldNewValue("MasterFile","DR Profile","2")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 57: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are Displayed Correctly"
Else
Reporter.ReportEvent micFail,"Step 57: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are NOt Displayed Correctly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Checks if the Flags are Present or Not
Call DRFlagCheck()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 56, 58:Verify
ing if Pending Approval Flags are Still present after Approving the Changes made
","The Pending Approval Flags are Not Present Next to the Modifed Fields after a
pproving the Changes made"
Else
Reporter.ReportEvent micFail,"Step 56 , 58: Veri
fying if Pending Approval Flags are Still present after Approving the Changes ma
de","The Pending Approval Flags are Still Present Next to the Modifed Fields aft
er approving the Changes made"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Logout from Application and Approver the Changes made
to the Approver
Call logoutfromApp("MasterFile","Corporate Action Data F
ix")
' Loging with Approval ID and Approve the Changes made to
the Issuer
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
Call ApprovalFunction_DR("MasterFile","Underlying Securi
ty","Name;Status;Last User Updated;Last Updated",Environment.Value("UnderlyingSe
curityName"),"Approved","Approved","Pending Approval")
'IssuerName_NewValue
If intTestCounter <> 2 Then
Environment.Value("DATATABLE_ROW")= Environment.
Value("DATATABLE_ROW") + 1
DataTable.GetSheet("DRLifeCycle").SetCurrentRow(
Environment.Value("DATATABLE_ROW"))
End If
Next
Call select_Menu("MasterFile","Corporate Action Data Fix","Home;DR Home"
)
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++++
' Data Fix
' Create DRs with Non BNYM Depository - 3 DRs for different NOn BNYM Depository
' ========= Perform Corporate Action by Selecting Data Fix from Drop down
Public Function DRLifeCycle_TC21()
For intTestCounter = 1 to 3
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" T
hen
Call CreateBifurcatedDR("MasterFile","Profile -
DR Search","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Sear
ch","DR Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR fo
r Performing DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRT
ype","DRLifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR
for Performing DR Life Cycle","The Required DR of type " & DataTable.Value("New
DRType","DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Login to the Application and Performing Corporate Acti
on on the DR
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call DR_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " Succe
ssfully"
Else
Reporter.ReportEvent micFail,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Not Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " S
uccessfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Underlying Security Pro
file")
'Loging with Approval ID and Approve the Changes made
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
' Approving the Changes
Call DRApprovalFunction_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 39 to 52: App
roving the Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 39 to 52: App
roving the Changes made to the DR","The Changes made are NOT Approved Successful
ly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Depositary Receipt Divi
sion's")
' Login again
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call click_WebElement("MasterFile","Depositary Receipt Divisi
on's","MasterFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("M
enuPath","DRLifeCycle"))
strStatus = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("Status").GetROProperty("value")
strDRType = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("DRType").GetROProperty("value")
strDROrigin = Browser("MasterFile").Page("Profile - DR S
earch").WebList("DROrigin").GetROProperty("value")
strCountryofManagement = Browser("MasterFile").Page("Pro
file - DR Search").WebList("CountryofManagement").GetROProperty("value")
SU = Browser("MasterFile").Page("Profile - DR Search").W
ebList("SU").GetROProperty("value")
strSubstatus = Browser("MasterFile").Page("Profile - DR
Search").WebList("SubStatus").GetROProperty("value")
strDRExchange = Browser("MasterFile").Page("Profile - DR
Search").WebList("DRExchange").GetROProperty("value")
If Instr(1,strStatus,"All") <> 0 And Instr(1,strDRType,"
All") <> 0 And Instr(1,strDROrigin,"All") <> 0 And Instr(1,strCountryofManagemen
t,"All") <> 0 And Instr(1,SU,"All") <> 0 And Instr(1,strSubstatus,"All") <> 0 An
d Instr(1,strDRExchange,"All") <> 0 Then
Reporter.ReportEvent micPass,"Step 53 to 54: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields are 'All' "
Else
Reporter.ReportEvent micFail,"Step 53 to 54: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields areNOT 'All' "
Environment.Value("Execution_Log") = "False"
End If
'Search for the Modified DR
Call ModifiedDRSearchCriteria("MasterFile","Profile - DR Sear
ch","Search")
intValues = Browser("MasterFile").Page("Profile - DR Search").WebTabl
e("DRSearchResults").GetRowWithCellText(DataTable.Value("DRName","DRLifeCycle"))
If intValues <> -1 Then
Reporter.ReportEvent micPass,"Step 55: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is displayed in the Search Result"
Else
Reporter.ReportEvent micFail,"Step 55: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is NOT displayed in the Search Result"
Environment.Value("Execution_Log") = "False"
End If
' Selecting the Required DR
Browser("MasterFile").Page("Profile - DR Search").WebEle
ment("html tag:=TD","innertext:="& DataTable.Value("NewValue","DRLifeCycle")).Cl
ick
Wait(5)
'Comparing the Old Values in the Audit log
Call CompareDROldNewValue("MasterFile","DR Profile","2")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 57: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are Displayed Correctly"
Else
Reporter.ReportEvent micFail,"Step 57: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are NOt Displayed Correctly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Checks if the Flags are Present or Not
Call DRFlagCheck()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 56,58: Verify
ing if Pending Approval Flags are Still present after Approving the Changes made
","The Pending Approval Flags are Not Present Next to the Modifed Fields after a
pproving the Changes made"
Else
Reporter.ReportEvent micFail,"Step 56, 58: Verif
ying if Pending Approval Flags are Still present after Approving the Changes mad
e","The Pending Approval Flags are Still Present Next to the Modifed Fields afte
r approving the Changes made"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Logout from Application and Approver the Changes made
to the Approver
Call logoutfromApp("MasterFile","Corporate Action Data F
ix")
' Loging with Approval ID and Approve the Changes made t
o the Issuer
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
Call ApprovalFunction_DR("MasterFile","Underlying Securi
ty","Name;Status;Last User Updated;Last Updated",Environment.Value("UnderlyingSe
curityName"),"Approved","Approved","Pending Approval")
'IssuerName_NewValue
If intTestCounter <> 3 Then
Environment.Value("DATATABLE_ROW")= Environment.
Value("DATATABLE_ROW") + 1
DataTable.GetSheet("DRLifeCycle").SetCurrentRow(
Environment.Value("DATATABLE_ROW"))
End If
Next
Call select_Menu("MasterFile","Corporate Action Data Fix","Home;DR Home"
)
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++++
' Data Fix
' Bifurcated
' Create a Bifurcated DRs with Non BNYM Depository for 144A Level and REgs -- N
on BNYM Depository
'============ Perform Corporate Action on 144A first and then with Reg.S
Public Function DRLifeCycle_TC22()
For intTestCounter = 1 to 2
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" T
hen
Call CreateBifurcatedDR("MasterFile","Profile -
DR Search","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Sear
ch","DR Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR fo
r Performing DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRT
ype","DRLifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR
for Performing DR Life Cycle","The Required DR of type " & DataTable.Value("New
DRType","DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Login to the Application and Performing Corporate Acti
on on the DR
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call DR_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " Succe
ssfully"
Else
Reporter.ReportEvent micFail,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Not Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " S
uccessfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Underlying Security Pro
file")
'Loging with Approval ID and Approve the Changes made
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
' Approving the Changes
Call DRApprovalFunction_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 39 to 52: App
roving the Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 39 to 52: App
roving the Changes made to the DR","The Changes made are NOT Approved Successful
ly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Depositary Receipt Divi
sion's")
' Login again
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call click_WebElement("MasterFile","Depositary Receipt Divisi
on's","MasterFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("M
enuPath","DRLifeCycle"))
strStatus = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("Status").GetROProperty("value")
strDRType = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("DRType").GetROProperty("value")
strDROrigin = Browser("MasterFile").Page("Profile - DR S
earch").WebList("DROrigin").GetROProperty("value")
strCountryofManagement = Browser("MasterFile").Page("Pro
file - DR Search").WebList("CountryofManagement").GetROProperty("value")
SU = Browser("MasterFile").Page("Profile - DR Search").W
ebList("SU").GetROProperty("value")
strSubstatus = Browser("MasterFile").Page("Profile - DR
Search").WebList("SubStatus").GetROProperty("value")
strDRExchange = Browser("MasterFile").Page("Profile - DR
Search").WebList("DRExchange").GetROProperty("value")
If Instr(1,strStatus,"All") <> 0 And Instr(1,strDRType,"
All") <> 0 And Instr(1,strDROrigin,"All") <> 0 And Instr(1,strCountryofManagemen
t,"All") <> 0 And Instr(1,SU,"All") <> 0 And Instr(1,strSubstatus,"All") <> 0 An
d Instr(1,strDRExchange,"All") <> 0 Then
Reporter.ReportEvent micPass,"Step 53 to 54: Verifying the Defau
lt Values of Fields in the Profile - DR Search page","The Default Values of the
Fields are 'All' "
Else
Reporter.ReportEvent micFail,"Step 53 to 54: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields areNOT 'All' "
Environment.Value("Execution_Log") = "False"
End If
'Search for the Modified DR
Call ModifiedDRSearchCriteria("MasterFile","Profile - DR Sear
ch","Search")
intValues = Browser("MasterFile").Page("Profile - DR Search").WebTabl
e("DRSearchResults").GetRowWithCellText(DataTable.Value("DRName","DRLifeCycle"))
If intValues <> -1 Then
Reporter.ReportEvent micPass,"Step 55: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is displayed in the Search Result"
Else
Reporter.ReportEvent micFail,"Step 55: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is NOT displayed in the Search Result"
Environment.Value("Execution_Log") = "False"
End If
' Selecting the Required DR
Browser("MasterFile").Page("Profile - DR Search").WebEle
ment("html tag:=TD","innertext:="& DataTable.Value("NewValue","DRLifeCycle")).Cl
ick
Wait(5)
'Comparing the Old Values in the Audit log
Call CompareDROldNewValue("MasterFile","DR Profile","2")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 57: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are Displayed Correctly"
Else
Reporter.ReportEvent micFail,"Step 57: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are NOt Displayed Correctly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Checks if the Flags are Present or Not
Call DRFlagCheck()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 56, 58: Verif
ying if Pending Approval Flags are Still present after Approving the Changes mad
e","The Pending Approval Flags are Not Present Next to the Modifed Fields after
approving the Changes made"
Else
Reporter.ReportEvent micFail,"Step 56, 58: Verif
ying if Pending Approval Flags are Still present after Approving the Changes mad
e","The Pending Approval Flags are Still Present Next to the Modifed Fields afte
r approving the Changes made"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Logout from Application and Approver the Changes made
to the Approver
Call logoutfromApp("MasterFile","Corporate Action Data F
ix")
'Loging with Approval ID and Approve the Changes made t
o the Issuer
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
Call ApprovalFunction_DR("MasterFile","Underlying Securi
ty","Name;Status;Last User Updated;Last Updated",Environment.Value("UnderlyingSe
curityName"),"Approved","Approved","Pending Approval")
'IssuerName_NewValue
If intTestCounter <> 2 Then
Environment.Value("DATATABLE_ROW")= Environment.
Value("DATATABLE_ROW") + 1
DataTable.GetSheet("DRLifeCycle").SetCurrentRow(
Environment.Value("DATATABLE_ROW"))
End If
Next
Call select_Menu("MasterFile","Corporate Action Data Fix","Home;DR Home"
)
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++++
' Data Fix
' Create a DR on any Level of BNY Type Depository
' ======================= Perform Corporate Action i.e., Data Fix
Public Function DRLifeCycle_TC23()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" T
hen
Call CreateBifurcatedDR("MasterFile","Profile -
DR Search","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Sear
ch","DR Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR fo
r Performing DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRT
ype","DRLifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR
for Performing DR Life Cycle","The Required DR of type " & DataTable.Value("New
DRType","DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Login to the Application and Performing Corporate Acti
on on the DR
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call DR_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " Succe
ssfully"
Else
Reporter.ReportEvent micFail,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Not Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " S
uccessfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Underlying Security Pro
file")
'Loging with Approval ID and Approve the Changes made
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
' Approving the Changes
Call DRApprovalFunction_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 39 to 64: App
roving the Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 39 to 64: App
roving the Changes made to the DR","The Changes made are NOT Approved Successful
ly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Depositary Receipt Divi
sion's")
' Login again
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call click_WebElement("MasterFile","Depositary Receipt Divisi
on's","MasterFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("M
enuPath","DRLifeCycle"))
strStatus = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("Status").GetROProperty("value")
strDRType = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("DRType").GetROProperty("value")
strDROrigin = Browser("MasterFile").Page("Profile - DR S
earch").WebList("DROrigin").GetROProperty("value")
strCountryofManagement = Browser("MasterFile").Page("Pro
file - DR Search").WebList("CountryofManagement").GetROProperty("value")
SU = Browser("MasterFile").Page("Profile - DR Search").W
ebList("SU").GetROProperty("value")
strSubstatus = Browser("MasterFile").Page("Profile - DR
Search").WebList("SubStatus").GetROProperty("value")
strDRExchange = Browser("MasterFile").Page("Profile - DR
Search").WebList("DRExchange").GetROProperty("value")
If Instr(1,strStatus,"All") <> 0 And Instr(1,strDRType,"
All") <> 0 And Instr(1,strDROrigin,"All") <> 0 And Instr(1,strCountryofManagemen
t,"All") <> 0 And Instr(1,SU,"All") <> 0 And Instr(1,strSubstatus,"All") <> 0 An
d Instr(1,strDRExchange,"All") <> 0 Then
'If strStatus = " All" And strDRType = " All" And strDRO
rigin = " All" And strCountryofManagement = " All" And SU = " All" And strSubsta
tus = " All" And strDRExchange = " All" Then
Reporter.ReportEvent micPass,"Step 65 to 66: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields are 'All' "
Else
Reporter.ReportEvent micFail,"Step 65 to 66: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields areNOT 'All' "
Environment.Value("Execution_Log") = "False"
End If
'Search for the Modified DR
Call ModifiedDRSearchCriteria("MasterFile","Profile - DR Sear
ch","Search")
intValues = Browser("MasterFile").Page("Profile - DR Search").WebTabl
e("DRSearchResults").GetRowWithCellText(DataTable.Value("DRName","DRLifeCycle"))
If intValues <> -1 Then
Reporter.ReportEvent micPass,"Step 67: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is displayed in the Search Result"
Else
Reporter.ReportEvent micFail,"Step 67: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is NOT displayed in the Search Result"
Environment.Value("Execution_Log") = "False"
End If
' Selecting the Required DR
Browser("MasterFile").Page("Profile - DR Search").WebEle
ment("html tag:=TD","innertext:="& DataTable.Value("NewValue","DRLifeCycle")).Cl
ick
Wait(5)
'Comparing the Old Values in the Audit log
Call CompareDROldNewValue("MasterFile","DR Profile","2")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 69: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are Displayed Correctly"
Else
Reporter.ReportEvent micFail,"Step 69: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are NOt Displayed Correctly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Checks if the Flags are Present or Not
Call DRFlagCheck()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 68, 70 to 76:
Verifying if Pending Approval Flags are Still present after Approving the Chang
es made","The Pending Approval Flags are Not Present Next to the Modifed Fields
after approving the Changes made"
Else
Reporter.ReportEvent micFail,"Step 68, 70 to 76:
Verifying if Pending Approval Flags are Still present after Approving the Chang
es made","The Pending Approval Flags are Still Present Next to the Modifed Field
s after approving the Changes made"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' ' Logout from Application and Approver the Changes made
to the Approver
' Call logoutfromApp("MasterFile","Corporate Action Data F
ix")
'
'' Loging with Approval ID and Approve the Changes made to
the Issuer
' Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
' Call Login("MasterFile","Login Page","Approver","MFLogin
")
' Call ApprovalFunction_DR("MasterFile","Issuer","",DataTa
ble.Value("IssuerName_NewValue"),"Approved","Approved","Pending Approval")
Call select_Menu("MasterFile","Corporate Action Data Fix
","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++
' Data Fix - Bifurcated
' Create a DR on of BNY Type Depository - 144 A and Regs -- Sponsored and BNYM
Depository
' ========================== Perform Corporate Action on 144A and Reg.S
Public Function DRLifeCycle_TC24()
For intTestCounter = 1 to 2
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" T
hen
Call CreateBifurcatedDR("MasterFile","Profile -
DR Search","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Sear
ch","DR Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR fo
r Performing DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRT
ype","DRLifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR
for Performing DR Life Cycle","The Required DR of type " & DataTable.Value("New
DRType","DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Login to the Application and Performing Corporate Acti
on on the DR
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call DR_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " Succe
ssfully"
Else
Reporter.ReportEvent micFail,"Step 1 to 38: Veri
fying if the Corporate Action is Done on the DR successfully","The Corporate Act
ion is Not Performed on the DR " & DataTable.Value("DRName","DRLifeCycle") & " S
uccessfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Underlying Security Pro
file")
'Loging with Approval ID and Approve the Changes made
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call Login("MasterFile","Login Page","Approver","MFLogin
")
' Approving the Changes
Call DRApprovalFunction_CorporateAction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 39 to 64: App
roving the Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 39 to 64: App
roving the Changes made to the DR","The Changes made are NOT Approved Successful
ly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call logoutfromApp("MasterFile","Depositary Receipt Divi
sion's")
' Login again
Call invoke_URL("MasterFile","Login Page",Environment.Va
lue("AppURL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call click_WebElement("MasterFile","Depositary Receipt Divisi
on's","MasterFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("M
enuPath","DRLifeCycle"))
strStatus = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("Status").GetROProperty("value")
strDRType = Browser("MasterFile").Page("Profile - DR Sea
rch").WebList("DRType").GetROProperty("value")
strDROrigin = Browser("MasterFile").Page("Profile - DR S
earch").WebList("DROrigin").GetROProperty("value")
strCountryofManagement = Browser("MasterFile").Page("Pro
file - DR Search").WebList("CountryofManagement").GetROProperty("value")
SU = Browser("MasterFile").Page("Profile - DR Search").W
ebList("SU").GetROProperty("value")
strSubstatus = Browser("MasterFile").Page("Profile - DR
Search").WebList("SubStatus").GetROProperty("value")
strDRExchange = Browser("MasterFile").Page("Profile - DR
Search").WebList("DRExchange").GetROProperty("value")
If Instr(1,strStatus,"All") <> 0 And Instr(1,strDRType,"
All") <> 0 And Instr(1,strDROrigin,"All") <> 0 And Instr(1,strCountryofManagemen
t,"All") <> 0 And Instr(1,SU,"All") <> 0 And Instr(1,strSubstatus,"All") <> 0 An
d Instr(1,strDRExchange,"All") <> 0 Then
Reporter.ReportEvent micPass,"Step 65 to 66: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields are 'All' "
Else
Reporter.ReportEvent micFail,"Step 65 to 66: Ver
ifying the Default Values of Fields in the Profile - DR Search page","The Defaul
t Values of the Fields areNOT 'All' "
Environment.Value("Execution_Log") = "False"
End If
'Search for the Modified DR
Call ModifiedDRSearchCriteria("MasterFile","Profile - DR Sear
ch","Search")
intValues = Browser("MasterFile").Page("Profile - DR Search").WebTabl
e("DRSearchResults").GetRowWithCellText(DataTable.Value("DRName","DRLifeCycle"))
If intValues <> -1 Then
Reporter.ReportEvent micPass,"Step 67: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is displayed in the Search Result"
Else
Reporter.ReportEvent micFail,"Step 67: Verifying
if the Required DR is displayed in the List or Not","The Required DR " & DataTa
ble.Value("DRName","DRLifeCycle") & " is NOT displayed in the Search Result"
Environment.Value("Execution_Log") = "False"
End If
' Selecting the Required DR
Browser("MasterFile").Page("Profile - DR Search").WebEle
ment("html tag:=TD","innertext:="& DataTable.Value("NewValue","DRLifeCycle")).Cl
ick
Wait(5)
'Comparing the Old Values in the Audit log
Call CompareDROldNewValue("MasterFile","DR Profile","2")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 69: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are Displayed Correctly"
Else
Reporter.ReportEvent micFail,"Step 69: Comapring
the Old Values and New Values of the DR and CUSIP by clicking on Audit Button",
"The Old and New Values are NOt Displayed Correctly"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Checks if the Flags are Present or Not
Call DRFlagCheck()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 67, 69 to 76:
Verifying if Pending Approval Flags are Still present after Approving the Chang
es made","The Pending Approval Flags are Not Present Next to the Modifed Fields
after approving the Changes made"
Else
Reporter.ReportEvent micFail,"Step 67, 69 to 76:
Verifying if Pending Approval Flags are Still present after Approving the Chang
es made","The Pending Approval Flags are Still Present Next to the Modifed Field
s after approving the Changes made"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'' Logout from Application and Approver the Changes made
to the Approver
'Call logoutfromApp("MasterFile","Corporate Action Data
Fix")
' Loging with Approval ID and Approve the Changes made t
o the Issuer
'Call invoke_URL("MasterFile","Login Page",Environment.V
alue("AppURL"))
'Call Login("MasterFile","Login Page","Approver","MFLogi
n")
'Call ApprovalFunction_DR("MasterFile","Issuer","",DataT
able.Value("IssuerName_NewValue"),"Approved","Approved","Pending Approval")
'IssuerName_NewValue
If intTestCounter <> 2 Then
Environment.Value("DATATABLE_ROW")= Environment.
Value("DATATABLE_ROW") + 1
DataTable.GetSheet("DRLifeCycle").SetCurrentRow(
Environment.Value("DATATABLE_ROW"))
End If
Next
Call select_Menu("MasterFile","Corporate Action Data Fix","Home;DR Home"
)
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
++++++++++++++++++++++++++++++++++++++++++++++++++++
' Created a Bifuracted BNYM DR ( 144A and Reg.S)
' Created a Bifuracted Non - BNYM DR ( 144A and Reg.S)
' Created a Level II or Level III and Warrent
' =============================== Test for the Functionality of Related , Previe
w Button.
' Search based on Issuer Name and Select Level II or Level III D
R.
Call set_WebEdit_Value("MasterFile","Profile - DR Search","Issue
rName",DataTable.Value("IssuerName","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
Call pageCheck_WebElementinTable("MasterFile","Profile - DR Sear
ch","Name;Country of Management;Type;Status;Sub-Status;S/U;Effective Date;Deposi
tary;Origin;Structure","")
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If Environment.Value("TestCase_Log") = "True" And intRowCount >
2 Then
Reporter.ReportEvent micPass,"Step 7: Verfiying the Sear
ch Result","The Result is Displayed Successfully with the Required Columns"
Else
Reporter.ReportEvent micPass,"Step 7: Verfiying the Sear
ch Result","The Results are Not Displayed Successfully with the Required Columns
"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Not Checked for the Expected Result
strLevelIIDRName = FindRequiredDR("BNY","Level II","Yes")
strBNYBifurcated144ADR = FindRequiredDR("BNY","144A","")
strBNYBifurcatedRegSDR = FindRequiredDR("BNY","Reg. S")
strNonBNYBifurcated144ADR = FindRequiredDR("CIT","144A","")
strNonBNYBifurcatedRegSDR = FindRequiredDR("CIT","Reg. S")
strRequiredDRs = strLevelIIDRName & ":" & strBNYBifurcated144ADR
& ":" & strBNYBifurcatedRegSDR & ":" & strNonBNYBifurcated144ADR & ":" & strNon
BNYBifurcatedRegSDR
' Step 7 to 20
strRequiredDR = Split(strRequiredDRs,":",-1,1)
For intValCounter = 0 to UBound(strRequiredDR)
strRequiredDRName = strRequiredDR(intValCounter)
Browser("MasterFile").Page("Profile - DR Search"
).WebElement("html tag:=TD","innertext:=" &strRequiredDRName).Click
Wait(5)
Call pageCheck_ImageOR("MasterFile","DR Profile","Save;Preview;R
elated")
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"St
ep " & intVal & ": Verifying the Buttons in the Page 'DR Profile'","The Required
Buttons namely 'Save, Related and Preview' are Present in the Page'"
Else
Reporter.ReportEvent micFail,"St
ep 6: Verifying the Buttons in the Page 'DR Profile'","The Required Buttons name
ly 'Save, Related and Preview' are NOT Present in the Page'"
Environment.Value("TestCase_Log"
) = "True"
Environment.Value("Execution_Log
") = "False"
End If
' Clicking the Related Button
Call click_Image("MasterFile","DR Profile","Rela
ted")
' Verifying if the Related DR is displayed or NO
T
intRowCount = Browser("MasterFile").Page("DR Pro
file").Frame("lookupFrame").WebTable("DR").RowCount
For intRowCounter = 1 to intRowCount
intColumnCount = Browser("MasterFile").P
age("DR Profile").Frame("lookupFrame").WebTable("DR").ColumnCount(intRowCounter)
For intColumnCounter = 1 to intColumnCou
nt
strCellData = Browser("MasterFil
e").Page("DR Profile").Frame("lookupFrame").WebTable("DR").GetCellData(intRowCou
nter,intColumnCounter)
If Instr(1,strCellData,DataTable
.Value("ModifiedDRName","DRLifeCycle")) <> 0 Then
blnFlag = "True"
Exit For
End If
Next
If blnFlag = "True" Then
Exit For
End If
Next
If blnFlag = "True" Then
Reporter.ReportEvent micPass,"Verifying
if the Related DR is displayed","The Related DR " & strNextDRName & " is display
ed when clicked on Related Profile Button"
Else
Reporter.ReportEvent micFail,"Verifying
if the Related DR is displayed","The Related DR " & strNextDRName & " is NOT dis
played when clicked on Related Profile Button"
Environment.Value("Execution_Log") = "Fa
lse"
Environment.Value("TestCase_Log") = "Fal
se"
End If
' Click on Preview Button
Call click_Image("MasterFile","DR Profile","Prev
iew")
' Verfiying the Preview Button functionality
blnFlag1 = Browser("MasterFile").Page("DR Profil
e").Frame("Frame").WebTable("Details").Exist(2)
blnFlag2 = Browser("MasterFile").Page("DR Profil
e").Frame("Frame").WebTable("CUSIPSummary").Exist(2)
blnFlag3 = Browser("MasterFile").Page("DR Profil
e").Frame("Frame").WebTable("Offering").Exist(2)
blnFlag4= Browser("MasterFile").Page("DR Profile
").Frame("Frame").WebTable("AdditionalDRExchange").Exist(2)
If blnFlag1 = "True" And blnFlag2 = "True" And b
lnFlag3 = "True" And blnFlag4 = "True" Then
Reporter.ReportEvent micPass,"Verifying
if the functionality of Preview Button","The Details, CUSIP Summary, Offering an
d the Additional DR Exchange details are displayed"
Else
Reporter.ReportEvent micFail,"Verifying
if the functionality of Preview Button","The Details, CUSIP Summary, Offering an
d the Additional DR Exchange details are NOT displayed"
Environment.Value("Execution_Log") = "Fa
lse"
Environment.Value("TestCase_Log") = "Fal
se"
End If
Wait(5)
If intValCounter <> UBound(strRequiredDR) Then
Browser("MasterFile").Page("DR Profile")
.WebElement("DRSearch").Click
End If
Wait(5)
Next
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 7 to 20: Verfiying th
e Functionality of Related and Preview buttons","The Related DRs are displayed w
hen clicked on Related DR button"
Else
Reporter.ReportEvent micFail,"Step 7 to 20: Verfiying th
e Functionality of Related and Preview buttons","The Related DRs are NOT display
ed when clicked on Related DR button"
Environment.Value("TestCase_Log") = "False"
Environment.Value("Execution_Log") = "False"
End If
' Clicking on Return button
Call click_Image("MasterFile","DR Profile","Back")
' Testing the Next and Prior DR Button functionality
If Browser("MasterFile").Page("DR Profile").WebButton("NextDR").
Exist(2) Then
Browser("MasterFile").Page("DR Profile").WebButton("Next
DR").Click
strDRName = get_WebEdit_Value("MasterFile","DR Profile",
"Details_Name")
If strDRName = DataTable.Value("ModifiedDRName","DRLifeC
ycle") Then
Reporter.ReportEvent micPass,"Step 21: Verifying
the Functionality of Next DR Button","The DR Next in the Hierarchy is displayed
"
Else
Reporter.ReportEvent micFail,"Step 21: Verifying
the Functionality of Next DR Button","The DR Next in the Hierarchy is NOT displ
ayed"
Environment.Value("Execution_Log") = "False"
End If
If Browser("MasterFile").Page("DR Profile").WebButton("P
riorDR").Exist(2) Then
Browser("MasterFile").Page("DR Profile").WebButt
on("PriorDR").Click
strDRName = get_WebEdit_Value("MasterFile","DR P
rofile","Details_Name")
If strDRName = DataTable.Value("DRName","DRLifeC
ycle") Then
Reporter.ReportEvent micPass,"Step 22: V
erifying the Functionality of Prior DR Button","The Prior DR in the Hierarchy is
displayed"
Else
Reporter.ReportEvent micFail,"Step 22: V
erifying the Functionality of Next DR Button","The Prior DR in the Hierarchy is
NOT displayed"
Environment.Value("Execution_Log") = "Fa
lse"
End If
End If
ElseIf Browser("MasterFile").Page("DR Profile").WebButton("Prior
DR").Exist(2) Then
Browser("MasterFile").Page("DR Profile").WebButton("Prio
rDR").Click
strDRName = get_WebEdit_Value("MasterFile","DR Profile",
"Details_Name")
If strDRName = DataTable.Value("DRName","DRLifeCycle")
Then
Reporter.ReportEvent micPass,"Step 21: Verifying
the Functionality of Prior DR Button","The Prior DR in the Hierarchy is display
ed"
Else
Reporter.ReportEvent micFail,"Step 21: Verifying
the Functionality of Next DR Button","The Prior DR in the Hierarchy is NOT dis
played"
Environment.Value("Execution_Log") = "False"
End If
If Browser("MasterFile").Page("DR Profile").WebButton("N
extDR").Exist(2) Then
Browser("MasterFile").Page("DR Profile").WebButt
on("NextDR").Click
strDRName = get_WebEdit_Value("MasterFile","DR P
rofile","Details_Name")
If strDRName = DataTable.Value("ModifiedDRName",
"DRLifeCycle") Then
Reporter.ReportEvent micPass,"Step 22: V
erifying the Functionality of Next DR Button","The DR Next in the Hierarchy is d
isplayed"
Else
Reporter.ReportEvent micFail,"Step 22: V
erifying the Functionality of Next DR Button","The DR Next in the Hierarchy is N
OT displayed"
Environment.Value("Execution_Log") = "Fa
lse"
End If
End If
End If
' Click on the Related DR Button
Call click_WebButton("MasterFile","DR Profile","RelatedDR")
strDRName = get_WebEdit_Value("MasterFile","DR Profile","Details
_Name")
If strDRName = DataTable.Value("ModifiedDRName","DRLifeCycle") T
hen
Reporter.ReportEvent micPass,"Step 23: Verifying the Fun
ctionality of Related DR Button","The Related DR Details is displayed"
Else
Reporter.ReportEvent micFail,"Step 23: Verifying the Fun
ctionality of Related DR Button","The Related DR Details is NOT displayed"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","Corporate Action Data Fix","Home;
DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++++++++++
' Test for the Functionality of Search Button
Public Function DRLifeCycle_TC26()
' Step 3
Call click_WebElement("MasterFile","Depositary Receipt Division'
s","MasterFile")
' Select DR Menu from Profile
Call select_Menu("MasterFile","MasterFile",DataTable.Value("MenuPath","D
RLifeCycle"))
' Verifying the Fields present in the Profile - DR Search
Call pageCheck_WebEditOR("MasterFile","Profile - DR Search","Iss
uerName;DRName")
Call pageCheck_WebListOR("MasterFile","Profile - DR Search","DRT
ype;DROrigin;CountryofManagement;Status;SubStatus;SU;DRExchange")
Call pageCheck_WebElementinTable("MasterFile","Profile - DR Sear
ch","Name;Country of Management;Type;Status;Sub-Status;S/U;Effective Date;Deposi
tary;Origin;Structure","")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 3: Verifying if all t
he Elements are Present in the Page 'Profile -DR Search'","All the Required Fiel
ds are Present in the Page 'Profile - DR Search'"
Else
Reporter.ReportEvent micFail,"Step 3: Verifying if all t
he Fields are Present in the Page 'Profile -DR Search'","All the Required Fields
are NOT Present in the Page 'Profile - DR Search'"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") =False
End If
' Step 4
strStatus = Browser("MasterFile").Page("Profile - DR Search").We
bList("Status").GetROProperty("value")
strDRType = Browser("MasterFile").Page("Profile - DR Search").We
bList("DRType").GetROProperty("value")
strDROrigin = Browser("MasterFile").Page("Profile - DR Search").
WebList("DROrigin").GetROProperty("value")
strCountryofManagement = Browser("MasterFile").Page("Profile - D
R Search").WebList("CountryofManagement").GetROProperty("value")
SU = Browser("MasterFile").Page("Profile - DR Search").WebList("
SU").GetROProperty("value")
strSubstatus = Browser("MasterFile").Page("Profile - DR Search")
.WebList("SubStatus").GetROProperty(" value")
strDRExchange = Browser("MasterFile").Page("Profile - DR Search"
).WebList("DRExchange").GetROProperty("value")
If strStatus = "All" And strDRType = "All" And strDROrigin = "Al
l" And strCountryofManagement = "All" And SU = "All" And strSubstatus = "All" An
d strDRExchange = "All" Then
Reporter.ReportEvent micPass,"Verifying the Default Valu
es of Fields in the Profile - DR Search page","The Default Values of the Fields
are 'All' "
Else
Reporter.ReportEvent micPass,"Verifying the Default Valu
es of Fields in the Profile - DR Search page","The Default Values of the Fields
are 'All' "
Environment.Value("Execution_Log") = "False"
End If
' Step 4
Call set_WebEdit_Value("MasterFile","Profile - DR Search","Issue
rName",DataTable.Value("IssuerName","DRLIfeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Need to verify the Expected Result of Step 4
' Step 5
Call set_WebEdit_Value("MasterFile","Profile - DR Search","Issue
rName",DataTable.Value("IssuerName","DRLIfeCycle"))
Call Select_Combo_Value("MasterFile","Profile - DR Search","DRType",Data
Table.Value("NewDRType","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Checking for the Results in the Result Table
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If intRowCount > 2 Then
Call chkResultinTable("MasterFile","Profile - DR
Search","DRSearchResults","Type",DataTable.Value("NewDRType","DRLifeCycle"))
If Environment.Value("TestCase_Log") = "True" T
hen
Reporter.ReportEvent micPass,"Step 5: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e displayed with the Value " & DataTable.Value("NewDRType","DRLifeCycle") & " in
the Column 'Type'"
Else
Reporter.ReportEvent micFail,"Step 5: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e NOT displayed with the Value " & DataTable.Value("NewDRType","DRLifeCycle") &
" in the Column 'Type'"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micWarning,"Step 5: Verifyi
ng if the Results are Displayed as per the Search Criteria","No Results are disp
layed for the Search Criteria ' Issuer Name : = " & DataTable.Value("IssuerName"
,"DRLifeCycle") & " and ' DRType := " & DataTable.Value("NewDRType","DRLifeCycle
")
End If
' Step 6
Call set_WebEdit_Value("MasterFile","Profile - DR Search","Issue
rName",DataTable.Value("IssuerName","DRLIfeCycle"))
Call Select_Combo_Value("MasterFile","Profile - DR Search","DROrigin",Da
taTable.Value("Origin","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Checking for the Results in the Result Table
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If intRowCount > 2 Then
Call chkResultinTable("MasterFile","Profile - DR
Search","DRSearchResults","Origin",DataTable.Value("Origin","DRLifeCycle"))
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"Step 6: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e displayed with the Value " & DataTable.Value("Origin","DRLifeCycle") & " in th
e Column 'Type'"
Else
Reporter.ReportEvent micFail,"Step 6: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e NOT displayed with the Value " & DataTable.Value("Origin","DRLifeCycle") & " i
n the Column 'Type'"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micWarning,"Step 6: Verifyi
ng if the Results are Displayed as per the Search Criteria","No Results are disp
layed for the Search Criteria ' Issuer Name : = " & DataTable.Value("IssuerName"
,"DRLifeCycle") & " and ' Origin := " & DataTable.Value("Origin","DRLifeCycle")
End If
' Step 7
Call set_WebEdit_Value("MasterFile","Profile - DR Search","IssuerName",D
ataTable.Value("IssuerName","DRLIfeCycle"))
Call Select_Combo_Value("MasterFile","Profile - DR Search","CountryofMan
agement",DataTable.Value("CountryofManagement","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Checking for the Results in the Result Table
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If intRowCount > 2 Then
Call chkResultinTable("MasterFile","Profile - DR
Search","DRSearchResults","Country of Management",DataTable.Value("CountryofMan
agement","DRLifeCycle"))
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"Step 7: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e displayed with the Value " & DataTable.Value("CountryofManagement","DRLifeCycl
e") & " in the Column 'Country of Management'"
Else
Reporter.ReportEvent micFail,"Step 7: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e NOT displayed with the Value " & DataTable.Value("CountryofManagement","DRLife
Cycle") & " in the Column 'Country of Management'"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micWarning,"Step 7: Verifyi
ng if the Results are Displayed as per the Search Criteria","No Results are disp
layed for the Search Criteria ' Issuer Name : = " & DataTable.Value("IssuerName"
,"DRLifeCycle") & " and ' Country of Management := " & DataTable.Value("Countryo
fManagement","DRLifeCycle")
End If
' Step 8 - Search based on Status
Call set_WebEdit_Value("MasterFile","Profile - DR Search","IssuerName",D
ataTable.Value("IssuerName","DRLIfeCycle"))
Call Select_Combo_Value("MasterFile","Profile - DR Search","Status",Data
Table.Value("Status","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Checking for the Results in the Result Table
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If intRowCount > 2 Then
Call chkResultinTable("MasterFile","Profile - DR
Search","DRSearchResults","Status",DataTable.Value("Status","DRLifeCycle"))
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"Step 8: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e displayed with the Value " & DataTable.Value("Status","DRLifeCycle") & " in th
e Column 'Status'"
Else
Reporter.ReportEvent micFail,"Step 8: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e NOT displayed with the Value " & DataTable.Value("Status","DRLifeCycle") & " i
n the Column 'Status'"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micWarning,"Step 8: Verifyi
ng if the Results are Displayed as per the Search Criteria","No Results are disp
layed for the Search Criteria ' Issuer Name : = " & DataTable.Value("IssuerName"
,"DRLifeCycle") & " and ' Status := " & DataTable.Value("Status","DRLifeCycle")
End If
' Step 9 - Search based on 'SubStatus
Call set_WebEdit_Value("MasterFile","Profile - DR Search","IssuerName",D
ataTable.Value("IssuerName","DRLIfeCycle"))
Call Select_Combo_Value("MasterFile","Profile - DR Search","SubStatus",D
ataTable.Value("SubStatus","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Checking for the Results in the Result Table
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If intRowCount > 2 Then
Call chkResultinTable("MasterFile","Profile - DR
Search","DRSearchResults","Sub-Status",DataTable.Value("SubStatus","DRLifeCycle
"))
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"Step 9: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e displayed with the Value " & DataTable.Value("SubStatus","DRLifeCycle") & " in
the Column 'SubStatus'"
Else
Reporter.ReportEvent micFail,"Step 9: Ve
rifying if the Results are Displayed as per the Search Criteria","The Results ar
e NOT displayed with the Value " & DataTable.Value("SubStatus","DRLifeCycle") &
" in the Column 'SubStatus'"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micWarning,"Step 9: Verifyi
ng if the Results are Displayed as per the Search Criteria","No Results are disp
layed for the Search Criteria ' Issuer Name : = " & DataTable.Value("IssuerName"
,"DRLifeCycle") & " and ' Sub-Status := " & DataTable.Value("SubStatus","DRLifeC
ycle")
End If
' Step 10 - Search based on S/U
Call set_WebEdit_Value("MasterFile","Profile - DR Search","IssuerName",D
ataTable.Value("IssuerName","DRLIfeCycle"))
Call Select_Combo_Value("MasterFile","Profile - DR Search","SU",DataTabl
e.Value("Sponsored","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Checking for the Results in the Result Table
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If intRowCount > 2 Then
Call chkResultinTable("MasterFile","Profile - DR
Search","DRSearchResults","S/U",DataTable.Value("Sponsored","DRLifeCycle"))
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"Step 10: V
erifying if the Results are Displayed as per the Search Criteria","The Results a
re displayed with the Value " & DataTable.Value("Sponsored","DRLifeCycle") & " i
n the Column 'S/U'"
Else
Reporter.ReportEvent micFail,"Step 10: V
erifying if the Results are Displayed as per the Search Criteria","The Results a
re NOT displayed with the Value " & DataTable.Value("Sponsored","DRLifeCycle") &
" in the Column 'S/U'"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micWarning,"Step 10: Verify
ing if the Results are Displayed as per the Search Criteria","No Results are dis
played for the Search Criteria ' Issuer Name : = " & DataTable.Value("IssuerName
","DRLifeCycle") & " and ' S/U := " & DataTable.Value("Sponsored","DRLifeCycle")
End If
Call select_Menu("MasterFile","Corporate Action Data Fix","Home;
DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++======+
Public Function DRLifeCycle_TC27()
' Call invoke_URL("MasterFile","Login Page",Environment.Value("URL"))
' Call Login("MasterFile","Login Page","Approval","MFLogin")
Call click_WebElement("MasterFile","Depositary Receipt Division's","Mast
erFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("MenuPath","D
RLifeCycle"))
' Step 11 - Search based on DRType and DR Exchange
Call set_WebEdit_Value("MasterFile","Profile - DR Search","IssuerName",D
ataTable.Value("IssuerName","DRLIfeCycle"))
Call Select_Combo_Value("MasterFile","Profile - DR Search","DRType",Data
Table.Value("NewDRType","DRLifeCycle"))
Call Select_Combo_Value("MasterFile","Profile - DR Search","DREx
change",DataTable.Value("DRExchange","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Checking for the Results in the Result Table
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If intRowCount > 2 Then
Call chkResultinTable("MasterFile","Profile - DR
Search","DRSearchResults","Type ",DataTable.Value("NewDRType","DRLifeCycle"))
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"Step 11: V
erifying if the Results are Displayed as per the Search Criteria","The Results a
re displayed with the Value " & DataTable.Value("NewDRType","DRLifeCycle") & " i
n the Column 'Type'"
Else
Reporter.ReportEvent micFail,"Step 11: V
erifying if the Results are Displayed as per the Search Criteria","The Results a
re NOT displayed with the Value " & DataTable.Value("NewDRType","DRLifeCycle") &
" in the Column 'Type'"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Else
Reporter.ReportEvent micWarning,"Step 11: Verify
ing if the Results are Displayed as per the Search Criteria","No Results are dis
played for the Search Criteria ' Issuer Name : = " & DataTable.Value("IssuerName
","DRLifeCycle") & " and ' Type := " & DataTable.Value("NewDRType","DRLifeCycle"
) & " and DR Exchange: = " & DataTable.Value("DRExchange","DRLifeCycle")
End If
' Step 12 - Search based on DR Type , Country of Management
Call set_WebEdit_Value("MasterFile","Profile - DR Search","Issue
rName",DataTable.Value("IssuerName","DRLIfeCycle"))
strDRType = "Reg. S"
Call Select_Combo_Value("MasterFile","Profile - DR Search","DRType",strD
RType)
Call Select_Combo_Value("MasterFile","Profile - DR Search","Coun
tryofManagement",DataTable.Value("CountryofManagement","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Checking for the Results in the Result Table
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If intRowCount > 2 Then
blnFlag = "False"
'Call chkResultinTable("MasterFile","Profile - D
R Search","DRSearchResults","Type ",DataTable.Value("DRType","DRLifeCycle"))
For intRowCounter = 3 to intRowCount
strDRTypes = Browser("MasterFile
").Page("Profile - DR Search").WebTable("DRSearchResults").GetCellData(intRowCou
nter,3)
strCountry = Browser("MasterFile
").Page("Profile - DR Search").WebTable("DRSearchResults").GetCellData(intRowCou
nter,2)
If strDRTypes <> "ERROR: The spe
cified cell does not exist." And strCountry <> "ERROR: The specified cell does
not exist." Then
If strDRTypes = DRType A
nd strCountry = DataTable.Value("CountryofManagement","DRLifeCycle") Then
blnFlag = "True"
End If
End If
Next
If blnFlag = "True" Then
Reporter.ReportEvent micPass,"Step 12: V
erifying if the Results are Displayed as per the Search Criteria","The Results a
re displayed with the Value " & strDRType & " in the Column 'Type' and " & DataT
able.Value("CountryofManagement","DRLifeCycle") & " in Column Country of Managem
ent"
Else
Reporter.ReportEvent micFail,"Step 12: V
erifying if the Results are Displayed as per the Search Criteria","The Results a
re NOT displayed with the Value " & strDRType & " in the Column 'Type' and " & D
ataTable.Value("CountryofManagement","DRLifeCycle") & " in Column Country of Man
agement"
Environment.Value("Execution_Log") = "False"
End If
Else
Reporter.ReportEvent micWarning,"Step 12: Verify
ing if the Results are Displayed as per the Search Criteria","No Results are dis
played for the Search Criteria ' Issuer Name : = " & DataTable.Value("IssuerName
","DRLifeCycle") & " and ' Type := " & strDRType & " and Country of Management:
= " & DataTable.Value("CountryofManagement","DRLifeCycle")
End If
' Step 13 - Search based on DR Type , Country of Management
Call set_WebEdit_Value("MasterFile","Profile - DR Search","Issue
rName",DataTable.Value("IssuerName","DRLIfeCycle"))
strDRType = "Reg. S"
Call Select_Combo_Value("MasterFile","Profile - DR Search","DRType",strD
RType)
Call Select_Combo_Value("MasterFile","Profile - DR Search","Stat
us",DataTable.Value("Status","DRLifeCycle"))
Call Select_Combo_Value("MasterFile","Profile - DR Search","Coun
tryofManagement",DataTable.Value("CountryofManagement","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
' Checking for the Results in the Result Table
intRowCount = Browser("MasterFile").Page("Profile - DR Search").
WebTable("DRSearchResults").RowCount
If intRowCount > 2 Then
blnFlag = "False"
'Call chkResultinTable("MasterFile","Profile - D
R Search","DRSearchResults","Type ",DataTable.Value("DRType","DRLifeCycle"))
For intRowCounter = 3 to intRowCount
strDRTypes = Browser("MasterFile
").Page("Profile - DR Search").WebTable("DRSearchResults").GetCellData(intRowCou
nter,3)
strCountry = Browser("MasterFile
").Page("Profile - DR Search").WebTable("DRSearchResults").GetCellData(intRowCou
nter,2)
strStatus = Browser("MasterFile"
).Page("Profile - DR Search").WebTable("DRSearchResults").GetCellData(intRowCoun
ter,4)
If strDRTypes <> "ERROR: The spe
cified cell does not exist." And strCountry <> "ERROR: The specified cell does
not exist." And strStatus <> "ERROR: The specified cell does not exist." Then
If strDRTypes = DRType A
nd strCountry = DataTable.Value("CountryofManagement","DRLifeCycle") And strStat
us = DataTable.Value("Status","DRLifeCycle") Then
blnFlag = "True"
End If
End If
Next
If blnFlag = "True" Then
Reporter.ReportEvent micPass,"Step 13: V
erifying if the Results are Displayed as per the Search Criteria","The Results a
re displayed with the Value " & strDRType & " in the Column 'Type' and " & DataT
able.Value("CountryofManagement","DRLifeCycle") & " in Column Country of Managem
ent and " & DataTable.Value("Status","DRLifeCycle") & " in Column 'Status'"
Else
Reporter.ReportEvent micFail,"Step 13: V
erifying if the Results are Displayed as per the Search Criteria","The Results a
re NOT displayed with the Value " & strDRType & " in the Column 'Type' and " & D
ataTable.Value("CountryofManagement","DRLifeCycle") & " in Column Country of Man
agement and " & DataTable.Value("Status","DRLifeCycle") & " in Column 'Status'"
Environment.Value("Execution_Log") = "False"
End If
Else
Reporter.ReportEvent micWarning,"Step 13: Verify
ing if the Results are Displayed as per the Search Criteria","No Results are dis
played for the Search Criteria ' Issuer Name : = " & DataTable.Value("IssuerName
","DRLifeCycle") & " and ' Type := " & strDRType & " and Country of Management:
= " & DataTable.Value("CountryofManagement","DRLifeCycle") & " and Status:= " &
DataTable.Value("Status","DRLifeCycle")
End If
Call select_Menu("MasterFile","Profile - DR Process","Home;DR Ho
me")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++
' Create a DR of Level II Iof Unsponsored DR and Non-Bny Depository
'===== Convert it to Sponsored Type DR with BNY Depository
Public Function DRLifeCycle_TC28()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 43: Verifying if
the DR is Converted successfully","The DR " & DataTable.Value("DRName","DRLifeC
ycle") & " is successfully Converted to Sponsored DR"
Else
Reporter.ReportEvent micFail,"Step 1 to 43: Verifying if
the DR is Upgraded successfully","The DR " & DataTable.Value("DRName","DRLifeCy
cle") & " is NOT successfully Converted to Sponsored DR"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 44 to 66: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 44 to 66: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 67 to 81: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 67 to 81: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++
' Create a Bifurcated Sponsored DR of Non-BNYM Depository
'================= Convert it to BNY Depository
Public Function DRLifeCycle_TC29()
'Create a New DR which has to under go Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
Call CreateBifurcatedDR("MasterFile","Profile - DR Searc
h","DR Profile","CUSIP Profile")
Else
Call CreateNewDR("MasterFile","Profile - DR Search","DR
Profile","CUSIP Profile")
End If
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Creating the DR for Perfor
ming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType","DR
LifeCycle") & " is created Successfully"
Else
Reporter.ReportEvent micWarning,"Creating the DR for Per
forming DR Life Cycle","The Required DR of type " & DataTable.Value("NewDRType",
"DRLifeCycle") & " is NOT created Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Login to the Application and Performing the DR Life Cycle
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","User","MFLogin")
Call UpdateDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 1 to 42: Verifying if
the Bifurcated DR is Converted from Non-BNYM to BNYM successfully","The DR " &
DataTable.Value("DRName","DRLifeCycle") & " is successfully Converted from Non-B
NYM to BNYM successfully"
Else
Reporter.ReportEvent micFail,"Step 1 to 42: Verifying if
the Bifurcated DR is Converted from Non-BNYM to BNYM successfully","The DR " &
DataTable.Value("DRName","DRLifeCycle") & " is NOT successfully Converted from N
on-BNYM to BNYM successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Loging with Approval ID and Approve the Changes made to the DR
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call Login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Changes while Performing DR Life Cycle
Call DRApprovalFunction()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 43 to 66: Approving t
he Changes made to the DR","The Changes made are Approved Successfully"
Else
Reporter.ReportEvent micFail,"Step 43 to 66: Approving t
he Changes made to the DR","The Changes made are NOT Approved Successfully"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
'Log out and Login with Normal User ID
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Logging in with Normal User ID and verfiy if all the changes m
ade are Approved and there are No Flags displayed
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
Call chkApprovedDR()
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 67 to 84: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are Approved and the Flags are Not Present"
Else
Reporter.ReportEvent micFail,"Step 67 to 84: Verfiying i
f the Modifed Fields are Approved and check for the Flags","The Modifeid Fields
are NOT Approved and the Flags are Present"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call select_Menu("MasterFile","DR Profile","Home;DR Home")
End Function
'+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+++++++++++++++++++++++++++++++++++++++++++++
'------------------------------------------------------- Functi
ons for DR Life Cycle Begins from here -----------------------------------------
-----------
'===============================================================================
============================================
Public Function DRApprovalFunction()
' strModuleName = Split(strModuleNames,";",-1,1)
' For intValCount = 0 to UBound(strModuleName)
' strRequiredModule = strModuleName(intValCount)
' Select Case strRequiredModule
' Case "DR Documen
tation"
'
Call ApprovalFunction_DR("MasterFile",strRequiredModule,"",DataTable.Value("Deta
ils_Name","DRLifeCycle"),"Approved","Approved","Pending Approval")
' Case "Issuer Doc
umentation"
'
Call ApprovalFunction_DR("MasterFile",strRequiredModule ,"",DataTable.Value("Iss
uerName","DRLifeCycle"),"Approved","Approved","Pending Approval")
' Case "CUSIP Prof
ile"
'
Call ApprovalFunction_DR("MasterFile",strRequiredModule,"",DataTable.Value("Sele
ctCUSIPName","DRLifeCycle"),"Approved","Approved","Pending Approval")
' Case "DR Profile
"
' Call ApprovalFunction_DR("MasterFi
le",strModuleName,"",DataTable.Value("Details_Name","DRLifeCycle"),"Approved","A
pproved","Pending Approval")
' End Select
' Next
If DataTable.Value("CreateCUSIP","DRLifeCycle") = "Y" Then
Call ApprovalFunction_DR("MasterFile","CUSIP Profile","N
ame;CUSIP;Last User Updated;Last Updated",DataTable.Value("SelectCUSIPName","DRL
ifeCycle"),"Approved","Approved","Pending Approval")
End If
If DataTable.Value("DRDocumentationRequired","DRLifeCycle") = "Y
" Then
Call ApprovalFunction_DR("MasterFile","DR Documentation"
,"DR Name;DR Type;S/U;Origin;DR Structure;Last User Updated;Last Updated",DataTa
ble.Value("Details_Name","DRLifeCycle"),"Approved","Approved","Pending Approval"
)
End If
If DataTable.Value("IssuerDocumentation","DRLifeCycle") = "Y" T
hen
Call ApprovalFunction_DR("MasterFile","Issuer Documentat
ion","Issuer;Last User Updated;Last Updated",DataTable.Value("Details_Name","DRL
ifeCycle"),"Approved","Approved","Pending Approval")
End If
Call ApprovalFunction_DR("MasterFile","DR Profile","Name;Type;De
positary;S/U;Origin;Structure;Last User Updated;Last Updated",DataTable.Value("D
etails_Name","DRLifeCycle"),"Approved","Approved","Pending Approval")
End Function
'===============================================================================
============================================
Public Function DRApprovalFunction_CorporateAction()
' Approving the Changes made to CUSIP
Call ApprovalFunction_DR("MasterFile","CUSIP Profile","Name;CUSIP;Last U
ser Updated;Last Updated",DataTable.Value("SelectCUSIPName","DRLifeCycle"),"Appr
oved","Approved","Pending Approval")
If DataTable.Value("CheckCorporateActionIssuerFlag","DRLifeCycle
") = "Y" Then
' Approving Underlying Security
Call ApprovalFunction_DR("MasterFile","Underlying Securi
ty","Name;Status;Last User Updated;Last Updated",Environment.Value("UnderlyingSe
curityName"),"Approved","Approved","Pending Approval")
' Approving the Issuer
Call ApprovalFunction_DR("MasterFile","Issuer","Name;Las
t User Updated;Last Updated",DataTable.Value("IssuerName","DRLifeCycle"),"Approv
ed","Approved","Pending Approval")
End If
' Approving the DR
Call ApprovalFunction_DR("MasterFile","DR Profile","Name;Type;De
positary;S/U;Origin;Structure;Last User Updated;Last Updated",DataTable.Value("D
RName","DRLifeCycle"),"Approved","Approved","Pending Approval")
End Function
'===============================================================================
============================================
End Function
'===============================================================================
=============================
Public Function UpdateDR()
strVar = Environment("TestDir")
strIndVar = Split(strVar,"\",-1,1)
strBound = UBound(strIndVar)
strAllPath =""
For intCounter = 0 to strBound - 1
strAllPath = strAllPath & strIndVar(intCounter)
&"\"
Next
strPath = Trim(strPath)
strDataPaths = strAllPath & "DataTables\"
If DataTable.Value("BifurcatedDR","DRLifeCycle") = "Y" Then
If DataTable.Value("NewDRType","DRLifeCycle") = "144A" T
hen
DataTable.Value("DRName","DRLifeCycle") = Enviro
nment.Value("DR144A")
DataTable.Value("CUSIPName","DRLifeCycle") = Env
ironment.Value("CUSIP144A")
DataTable.Value("SelectCUSIPName","DRLifeCycle")
= Environment.Value("SelectCUSIP144A")
ElseIf DataTable.Value("NewDRType","DRLifeCycle") = "Reg
. S" Then
DataTable.Value("DRName","DRLifeCycle") = Enviro
nment.Value("DRRegS")
DataTable.Value("CUSIPName","DRLifeCycle") = Env
ironment.Value("CUSIPRegS")
DataTable.Value("SelectCUSIPName","DRLifeCycle")
= Environment.Value("SelectCUSIPRegS")
End If
End If
DataTable.ExportSheet strDataPaths & "DRLifeCycle.xls","DRLifeCy
cle"
DataTable.ImportSheet strDataPaths & "DRLifeCycle.xls","DRLifeCycle","DR
LifeCycle"
' Step 3
Call click_WebElement("MasterFile","Depositary Receipt Division'
s","MasterFile")
' Step 4
Call check_Menu("MasterFile","MasterFile",DataTable.Value("MenuP
ath","DRLifeCycle"))
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 4: Verifying if the S
ub Menu DR is Present in Profile or NOT","The Sub Menu DR is Present in the Prof
ile Menu"
Else
Reporter.ReportEvent micFail,"Step 4: Verifying if the S
ub Menu DR is Present in Profile or NOT","The Sub Menu DR is NOT Present in the
Profile Menu"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Step 5
Call select_Menu("MasterFile","MasterFile",DataTable.Value("Menu
Path","DRLifeCycle"))
Call pageCheck_WebEditOR("MasterFile","Profile - DR Search","Iss
uerName;DRName")
Call pageCheck_WebListOR("MasterFile","Profile - DR Search","DRT
ype;DROrigin;CountryofManagement;Status;SubStatus;SU;DRExchange")
Call pageCheck_WebElementinTable("MasterFile","Profile - DR Sear
ch","Name;Country of Management;Type;Status;Sub-Status;S/U;Effective Date;Deposi
tary;Origin;Structure","")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 5: Verifying if all t
he Elements are Present in the Page 'Profile -DR Search'","All the Required Fiel
ds are Present in the Page 'Profile - DR Search'"
Else
Reporter.ReportEvent micFail,"Step 5: Verifying if all t
he Fields are Present in the Page 'Profile -DR Search'","All the Required Fields
are NOT Present in the Page 'Profile - DR Search'"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") =False
End If
' Step 6
strStatus = Browser("MasterFile").Page("Profile - DR Search").WebList("S
tatus").GetROProperty("value")
strDRType = Browser("MasterFile").Page("Profile - DR Search").We
bList("DRType").GetROProperty("value")
strDROrigin = Browser("MasterFile").Page("Profile - DR Search").
WebList("DROrigin").GetROProperty("value")
strCountryofManagement = Browser("MasterFile").Page("Profile - D
R Search").WebList("CountryofManagement").GetROProperty("value")
SU = Browser("MasterFile").Page("Profile - DR Search").WebList("
SU").GetROProperty("value")
strSubstatus = Browser("MasterFile").Page("Profile - DR Search")
.WebList("SubStatus").GetROProperty("value")
strDRExchange = Browser("MasterFile").Page("Profile - DR Search"
).WebList("DRExchange").GetROProperty("value")
If Instr(1,strStatus,"All") <> 0 And Instr(1,strDRType,"All") <>
0 And Instr(1,strDROrigin,"All") <> 0 And Instr(1,strCountryofManagement,"All")
<> 0 And Instr(1,SU,"All") <> 0 And Instr(1,strSubstatus,"All") <> 0 And Instr(
1,strDRExchange,"All") <> 0 Then
Reporter.ReportEvent micPass,"Verifying the Default Valu
es of Fields in the Profile - DR Search page","The Default Values of the Fields
are 'All' "
Else
Reporter.ReportEvent micFail,"Verifying the Default Valu
es of Fields in the Profile - DR Search page","The Default Values of the Fields
areNOT 'All' "
Environment.Value("Execution_Log") = "False"
End If
' Search for DR
Call DRSearchCriteria("MasterFile","Profile - DR Search","Search
")
Call pageCheck_ImageOR("MasterFile","Profile - DR Search","Clear
;Search")
'Call chkResultinTable("MasterFile","Profile - DR Search","DRSea
rchResults","Name",DataTable.Value("DRName","DRLifeCycle"))
Call chkResultinTable("MasterFile","Profile - DR Search","DRSear
chResults","Type",DataTable.Value("NewDRType","DRLifeCycle"))
Call chkResultinTable("MasterFile","Profile - DR Search","DRSear
chResults","S/U",DataTable.Value("Sponsored","DRLifeCycle"))
Call chkResultinTable("MasterFile","Profile - DR Search","DRSear
chResults","Status",DataTable.Value("DRStatus","DRLifeCycle"))
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 6: Verifying if the R
esults are Displayed or NOT","The Results are Dispalyed as per the Search Criter
ia"
Else
Reporter.ReportEvent micFail,"Step 6: Verifying if the R
esults are Displayed or NOT","The Results are NOT Dispalyed as per the Search Cr
iteria"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Step 7: Selecting a DR
Browser("MasterFile").Page("Profile - DR Search").WebElement("ht
ml tag:=TD","innertext:=" & DataTable.Value("DRName","DRLifeCycle"),"index:=2").
Click
Wait (5)
If Browser("MasterFile").Page("DR Profile").Exist(5) Then
strName = get_WebEdit_Value("MasterFile","DR Profile","D
etails_Name")
If Trim(UCase(strName)) = Trim(UCase(DataTable.Value("DR
Name","DRLifeCycle"))) Then
Reporter.ReportEvent micPass,"Step 7: Verifiyng
if the Details of the DR is Displayed or NOT","The Details of the DR " & DataTab
le.Value("DRName","DRLifeCycle") & " is displayed"
Else
Reporter.ReportEvent micFail,"Step 7: Verifiyng
if the Details of the DR is Displayed or NOT","The Details of the DR " & DataTab
le.Value("DRName","DRLifeCycle") & " NOT is displayed"
Environment.Value("Execution_Log") = "False"
End If
End If
' Step 8: Selecting DR Life Cycle
Call click_WebElement("MasterFile","DR Profile","DRLifeCycle")
strDRName = Browser("DR Lifecycle").Page("DR Lifecycle").WebTabl
e("DR").GetCellData(1,2)
strCountry = Browser("DR Lifecycle").Page("DR Lifecycle").WebTab
le("DR").GetCellData(1,4)
blnFlag = "False"
If UCase(Trim(strDRName)) = UCase(Trim(DataTable.Value("DRName","DRLifeC
ycle"))) Then
blnFlag = "True"
End If
Call pageCheck_ImageOR("DR Lifecycle","DR Lifecycle","CreateNewD
R;Cancel")
Call pageCheck_WebRadioGroupOR("DR Lifecycle","DR Lifecycle","Up
grade")
strSUValue = get_WebList_Value("DR Lifecycle","DR Lifecycle","SU
")
strDepositary = get_WebEdit_Value("DR Lifecycle","DR Lifecycle",
"Depositary")
' Step 9
Browser("DR Lifecycle").Page("DR Lifecycle").WebRadioGroup("Upgr
ade").Select DataTable("RadioGroupValue","DRLifeCycle")
' Select the Level to UPGrade
If DataTable.Value("DRLifeCycleType","DRLifeCycle") = "Upgrade"
Then
strAllItems = Browser("DR Lifecycle").Page("DR Lifecycle").WebList("
Upgrade").GetROProperty("all items")
Call Select_Combo_Value("DR Lifecycle","DR Lifecycle","Upgrade",Data
Table.Value("UpgradeLevel","DRLifeCycle"))
End If
' PPC
If DataTable.Value("DRLifeCycleType","DRLifeCycle") = "PPC" Then
strAllItems = Browser("DR Lifecycle").Page("DR Lifecycle").WebList("
PPCType").GetROProperty("all items")
Call Select_Combo_Value("DR Lifecycle","DR Lifecycle","P
PCType",DataTable.Value("UpgradeLevel","DRLifeCycle"))
End If
' Delisting
If DataTable.Value("DRLifeCycleType","DRLifeCycle") = "Delistin
g" Then
strAllItems = Browser("DR Lifecycle").Page("DR Lifecycle").WebList(
"Delist").GetROProperty("all items")
Call Select_Combo_Value("DR Lifecycle","DR Lifecycle","D
elist",DataTable.Value("UpgradeLevel","DRLifeCycle"))
End If
blnFlag = "True"
strNotRequiredValue = DataTable.Value("NewDRType","DRLifeCycle")
strAppItems = Split(strAllItems,";",-1,1)
For intCounters = 0 to UBound(strAppItems)
If strAppItems(intCounters) = strNotRequiredValue Then
blnFlag = "False"
End If
Next
If blnFlag = "True" AND strSUValue = DataTable("Sponsored","DRL
ifeCycle") AND blnFlag = "True" AND strDepositary = "" Then
Reporter.ReportEvent micPass,"Step 8: Verfiying the Fiel
ds Present and Values in few Fields","The Required Fields are Present and the Re
quired Values are Dispalyed in the Fields"
Else
Reporter.ReportEvent micFail,"Step 8: Verfiying the Fiel
ds Present and Values in few Fields","The Required Fields are NOT Present OR the
Required Values are NOT Dispalyed in the Fields"
'Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Selecting Sponsored or Unsponsored
If DataTable.Value("ModifiedSU","DRLifeCycle") <> "" Then
Call Select_Combo_Value("DR Lifecycle","DR Lifecycle","S
U",DataTable.Value("ModifiedSU","DRLifeCycle"))
End If
' Selecting the Depository
If DataTable.Value("Depositary","DRLifeCycle") <> "" Then
Call click_Image("DR Lifecycle","DR Lifecycle","Depositary")
intRowCount = Browser("DR Lifecycle").Page("DR Lifecycle
").Frame("lookupFrame").WebTable("Depositaries").RowCount
For intRowCounter = 1 to intRowCount
strName = Browser("DR Lifecycle").Page("DR Lifec
ycle").Frame("lookupFrame").WebTable("Depositaries").GetCellData(intRowCounter,2
)
If UCase(strName) = Ucase(DataTable.Value("Depos
itary","DRLifeCycle")) Then
intRC = intRowCounter
Exit For
End If
Next
Browser("DR Lifecycle").Page("DR Lifecycle").Frame("look
upFrame").WebTable("Depositaries").ChildItem(intRC,1,"WebCheckBox","0").Click
Browser("DR Lifecycle").Page("DR Lifecycle").Frame("look
upFrame").WebButton("Ok").Click
End If
'===============================================================================
' Written for Underlying Notification
Public Function chkResultinDRTable(strBrowserName, strPageName, strTableName, st
rDRName, strColumnName, strColumnValue)
' Gets the Column Number of the Column thats Needs to be verifie
d
blnExistFlag = "True"
blnFlag = "False"
intRowCount = Browser(strBrowserName).Page(strPageName).WebTable(strTabl
eName).RowCount
For intRowCounter = 1 To intRowCount
intColumnCount = Browser(strBrowserName).Page(strPageName).WebTable(
strTableName).ColumnCount(intRowCounter)
For intColumnCounter = 1 To intColumnCount
strCellData = Browser(strBrowserName).Page(strPageName).WebTable
(strTableName).GetCellData(intRowCounter, intColumnCounter)
If strCellData = strColumnName Then
intColumn = intColumnCounter
'intRow = intRowCounter
blnFlag = "True"
Exit For
End If
Next
If blnFlag = "True" Then
Exit For
End If
Next
' Gets the Row Number of the DR
blnFlag = "False"
intRowCount = Browser(strBrowserName).Page(strPageName).WebTable
(strTableName).RowCount
For intRowCounter = 1 To intRowCount
' intColumnCount = Browser(strBrowserName).Page(strPageName).WebTable
(strTableName).ColumnCount(intRowCounter)
' For intColumnCounter = 1 To intColumnCount
strCellData = Browser(strBrowserName).Page(strPageName).WebTable
(strTableName).GetCellData(intRowCounter, 1)
If UCase(Trim(strCellData)) = UCase(Trim(strDRName)) Then
intRow = intRowCounter
blnFlag = "True"
Exit For
End If
Next
' If blnFlag = "True" Then
' Exit For
' End If
'Next
' Checks for the Value in that Particlar Column in that Row
strReqValue = Browser(strBrowserName).Page(strPageName).WebTable(strTabl
eName).GetCellData(intRow,intColumn)
If UCase(Trim(strReqValue)) = UCase(Trim(strColumnValue)) Then
Reporter.ReportEvent micPass,"Verfiying if the Required
Value is dispalyed in the Column","The Value dispalyed in the Column "& strColum
nName & " is " & strColumnValue
Else
Reporter.ReportEvent micFail,"Verfiying if the Required
Value is dispalyed in the Column","The Value dispalyed in the Column "& strColum
nName & "is NOT " & strColumnValue
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "False"
End If
'===============================================================================
=============================================
Public Function ModifiedDRSearchCriteria(strBrowserName,strPageName,strImageName
)
If DataTable.Value("IssuerName","DRLifeCycle") <> "" Then
Call set_WebEdit_Value(strBrowserName,strPageName,"IssuerName",DataTa
ble.Value("IssuerName","DRLifeCycle"))
ElseIf DataTable.Value("CheckCorporateActionIssuerFlag","DRLifeCycle") =
"Y" Then
Call set_WebEdit_Value(strBrowserName,strPageName,"IssuerName",D
ataTable.Value("IssuerName_NewValue","DRLifeCycle"))
End If
If DataTable.Value("Details_Name","DRLifeCycle") <> "" Then
Call set_WebEdit_Value(strBrowserName,strPageName,"DRName",DataTable.
Value("Details_Name","DRLifeCycle"))
Else
Call set_WebEdit_Value(strBrowserName,strPageName,"DRName",DataT
able.Value("NewValue","DRLifeCycle"))
End If
If DataTable.Value("UpgradeLevel","DRLifeCycle") <> "" Then
Call Select_Combo_Value(strBrowserName,strPageName,"DRType",DataTable
.Value("UpgradeLevel","DRLifeCycle"))
End If
If DataTable.Value("ModifiedSU","DRLifeCycle") <> "" Then
Call Select_Combo_Value(strBrowserName,strPageName,"SU",DataTable.Val
ue("ModifiedSU","DRLifeCycle"))
End If
If DataTable.Value("DRStatus","DRLifeCycle") <> "" Then
Call Select_Combo_Value(strBrowserName,strPageName,"Status",DataTable
.Value("DRStatus","DRLifeCycle"))
End If
Call Click_Image(strBrowserName,strPageName,strImageName)
End Function
'===============================================================================
===================================================
' Name of the Function : CreateNewCUSIPForDR
' Scope of the Function : Public
' Author : Shyam H D
' Description : This function is used to CREATE A NEW CUSIP in
While Creating a DR
' Parameters accepted : BrowserName, PageName, Table Name and Image Na
me i.e., Save
' Parameter returned : Nill
' Date and / or Version : 22-11-2008,version 1.0
'===============================================================================
===================================================
Public Function CreateNewCUSIPForDR(strBrowserName,strPageName,strImageName)
strCUSIPDefaultName = set_WebEdit_Value(strBrowserName,strPageNa
me,"CUSIPName")
strFirstChar = Mid(strCUSIPDefaultName,1,1)
strCurrentTime = Time
strCurrentDate = Date
strDate = Split(strCurrentDate,"/" ,-1,1)
strTime = Split(strCurrentTime,":",-1,1)
strDateTimeStamp = strDate(0) &strDate(1)&strDate(2) & " "& str
Time(0) & strTime(1) & strTime(2)
If Asc(strFirstChar) = 94 or Asc(strFirstChar) = 38 Then
CUSIPNames = "QTPCUSIP_" & strDateTimeStamp
Else
CUSIPNames = strFirstChar & "QTPCUSIP_" & strDateTimeSta
mp
End If
CUSIPName = Replace(CUSIPNames," ","")
strCurrentTime = Time
strTime = Split(strCurrentTime,":",-1,1)
strIndTime = Split(strTime(2)," ",-1,1)
strTimeStamp = strTime(0) & strTime(1) & strIndTime(0) &strIndTi
me(1)
CUSIPNo = "0" & strTimeStamp
DataTable.Value("CUSIPName", "DRLifeCycle") = CUSIPName
DataTable.Value("CUSIP", "DRLifeCycle") = CUSIPNo
strVar1 = Environment("TestDir")
strIndVar1 = Split(strVar1,"\",-1,1)
strBound = UBound(strIndVar1)
strAllPath1 =""
For intCounters = 0 to strBound - 1
strAllPath1 = strAllPath1 & strIndVar1(intCounte
rs) &"\"
Next
strPath1 = Trim(strPath1)
strDataPath1 = strAllPath1 & "DataTables\"
DataTable.ExportSheet strDataPath1 & "DRLifeCycle.xls","DRLifeCycle"
DataTable.AddSheet "DRLifeCycle"
DataTable.ImportSheet strDataPath1 & "MasterFileProfile.xls","DR
LifeCycle","DRLifeCycle"
If DataTable.Value("CUSIPName","DRLifeCycle") <> "" Then
Call set_WebEdit_Value(strBrowserName,strPageNam
e,"CUSIPName",DataTable.Value("CUSIPName","DRLifeCycle"))
End If
If DataTable.Value("BriefName","DRLifeCycle") <> "" Then
Call set_WebEdit_Value(strBrowserName,strPageNam
e,"BriefName",DataTable.Value("BriefName","DRLifeCycle"))
End If
If DataTable.Value("RatioDRs","DRLifeCycle") <> "" Then
Call set_WebEdit_Value(strBrowserName,strPageNam
e,"RatioDRs",DataTable.Value("RatioDRs","DRLifeCycle"))
End If
If DataTable.Value("RatioUnderlyingShares","DRLifeCycle") <> ""
Then
Call set_WebEdit_Value(strBrowserName,strPageNam
e,"RatioUnderlyingShares",DataTable.Value("RatioUnderlyingShares","DRLifeCycle")
)
End If
If DataTable.Value("DRExchange","DRLifeCycle") <> "" Then
Call SelectImage(strBrowserName,strCUSIPPageName
,"Detail","DR Exchange","info.gif")
'Call click_Image(strBrowserName,strCUSIPPageName,"DRExchange")
Call SelectDRExchange(strBrowserName,strCUSIPPag
eName,"Exchange",DataTable.Value("DRExchange","DRLifeCycle"))
End If
If DataTable.Value("DRTickerSymbol","DRLifeCycle") <> "" Then
Call set_WebEdit_Value(strBrowserName,strPageNam
e,"DRTickerSymbol",DataTable.Value("DRTickerSymbol","DRLifeCycle"))
End If
Call SelectImage(strBrowserName,strPageName,"Detail","Underlying
Security","info.gif")
'Call click_Image(strBrowserName,strPageName,"UnderlyingSecurity
")
Call SelectValueinFrame(strBrowserName,strPageName,"lookupFrame"
,"Exchange")
If DataTable.Value("CUSIP","CUSIP") <> "" Then
Call set_WebEdit_Value(strBrowserName,strPageNam
e,"CUSIP",DataTable.Value("CUSIP","CUSIP"))
If Browser(strBrowserName).Dialog("Microsoft Int
ernet Explorer").Exist(2) Then
Browser(strBrowserName).Dialog("
Microsoft Internet Explorer").WinButton("OK").Click
End If
End If
Call click_Image(strBrowserName,strPageName,strImageName)
End Function
'=============================================================================
Public Function FillDRDocumentation(strBrowserName,strPageName)
If DataTable.Value("LawGoverningDepositAgreement","DRLifeCycle") <> "" Then
Call Select_Combo_Value(strBrowserName,strPageName,"LawGoverning",Dat
aTable.Value("LawGoverningDepositAgreement","DRLifeCycle"))
End If
If Environment.Value("SponserUnsponser") = "S" Then
If DataTable.Value("DepositAgreementDate","DRLifeCycle")
= "Y" Then
Call click_Image(strBrowserName,strPageName,"DepositA
greementDate")
Browser("MasterFile").Page("DR Documentation Detail")
.Frame("PopCalFrame").WebElement("Today").Click
If Browser("MasterFile").Dialog("Microsoft Internet E
xplorer").Exist(2) Then
Browser("MasterFile").Dialog("Microsoft Inter
net Explorer").WinButton("OK").Click
End If
End If
End If
If Environment.Value("SponserUnsponser") = "S" Then
If DataTable.Value("DepositAgreementAmendedDate","DRLifeCycle")
= "Y" Then
Call click_Image(strBrowserName,strPageName,"DepositAgre
ementAmendedDate")
Browser("MasterFile").Page("DR Documentation Detail").Fr
ame("PopCalFrame").WebElement("Today").Click
If Browser("MasterFile").Dialog("Microsoft Internet Expl
orer").Exist(2) Then
Browser("MasterFile").Dialog("Microsoft Internet
Explorer").WinButton("OK").Click
End If
End If
End If
If DataTable.Value("VotingType","DRLifeCycle") <> "" Then
Call Select_Combo_Value(strBrowserName,strPageName,"VotingType",DataT
able.Value("VotingType","DRLifeCycle"))
End If
If DataTable.Value("LawFirmBNY","DRLifeCycle") <> "" Then
Call SelectImage("MasterFile","DR Documentation Detail","DepositAgreem
ent","Law Firm - BNY","info.gif")
'Call click_Image(strBrowserName,strPageName,"LawFirmBNY")
Browser(strBrowserName).Page(strPageName).WebElement("html tag:=TD","
innertext:= " & DataTable.Value("LawFirmBNY","DRLifeCycle")).Click
End If
If DataTable.Value("LawFirmIssuer","DRLifeCycle") <> "" Then
Call SelectImage("MasterFile","DR Documentation Detail","Deposit
Agreement","Law Firm - Issuer","info.gif")
'Call click_Image(strBrowserName,strPageName,"LawFirmIssuer")
Browser(strBrowserName).Page(strPageName).WebElement("html tag:=TD","
innertext:= " & DataTable.Value("LawFirmIssuer","DRLifeCycle")).Click
End If
If DataTable.Value("LawFirmInvestmentBank","DRLifeCycle") <> "" Then
Call SelectImage("MasterFile","DR Documentation Detail","Deposit
Agreement","Law Firm - Investment Bank","info.gif")
'Call click_Image(strBrowserName,strPageName,"LawFirmInvestmentBank")
Browser(strBrowserName).Page(strPageName).WebElement("html tag:=TD","
innertext:= " & DataTable.Value("LawFirmInvestmentBank","DRLifeCycle")).Click
End If
If DataTable.Value("InvestmentBank","DRLifeCycle") <> "" Then
Call SelectImage("MasterFile","DR Documentation Detail","Deposit
Agreement","Investment Bank","info.gif")
'Call click_Image(strBrowserName,strPageName,"InvestmentBank")
Browser(strBrowserName).Page(strPageName).WebElement("html tag:=TD","
innertext:= " & DataTable.Value("InvestmentBank","DRLifeCycle")).Click
End If
If DataTable.Value("PreReleaseSideLetter","DRLifeCycle") <> "" Then
Call Select_Combo_Value(strBrowserName,strPageName,"PreReleas
eSideLetter",DataTable.Value("PreReleaseSideLetter","DRLifeCycle"))
End If
If Environment.Value("SponserUnsponser") = "S" Then
If DataTable.Value("OperationalChecklist","DRLifeCycle") <> ""
Then
Call Select_Combo_Value(strBrowserName,strPageName,"Oper
ationalChecklist",DataTable.Value("OperationalChecklist","DRLifeCycle"))
End If
End If
If DataTable.Value("TerminationPeriod","DRLifeCycle") <> "" Then
Call Select_Combo_Value(strBrowserName,strPageName,"TerminationPeriod
",DataTable.Value("TerminationPeriod","DRLifeCycle"))
End If
If DataTable.Value("BlockingType","DRLifeCycle") <> "" Then
Call Select_Combo_Value(strBrowserName,strPageName,"BlockingType",Dat
aTable.Value("BlockingType","DRLifeCycle"))
End If
Call Click_Image(strBrowserName,strPageName,"Save")
End Function
'===============================================================================
===================================================
' Name of the Function : FlagImageCheckAllRow
' Scope of the Function : Public
' Author : Shyam H D
' Description : This function checks for the New and Approval
Image in for all the Rows in a Table
' Parameters accepted : BrowserName, PageName, Table Name and the Cond
tion "Exist" or Not Exist
' Parameter returned : Null
' Date and / or Version : 22-11-2008,version 1.0
'===============================================================================
===================================================
'Call FlagImageCheckAllRow("MasterFile","DR Documentation Detail","Fees","Fee Ty
pe","Exist")
Public Function FlagImageCheckAllRow(strBrowserName, strPageName, strTableName,
strElementName, strCheckFlag)
blnFlag = "False"
intRowCount = Browser(strBrowserName).Page(strPageName).WebTable(strTableNam
e).RowCount
For intCounter = 1 to intRowCount
intColCounter = Browser("MasterFile").Page("DR Documentation Det
ail").WebTable("Fees").ColumnCount(intCounter)
For intCC = 1 to intColCounter
strCell = Browser("MasterFile").Page("DR Documentation D
etail").WebTable("Fees").GetCellData(intCounter,intCC)
If Trim(strCell) = Trim(strElementName) Then
intReqRow = intCounter + 1
blnFlag = "True"
Exit For
End If
Next
If blnFlag = "True" Then
Exit For
End If
Next
If blnFlag = "True" Then
For intRowCounter = intReqRow to intRowCount
blnFlag = "False"
intColumnCount = Browser(strBrowserName).Page(strPageName).WebTa
ble(strTableName).ColumnCount(intRowCounter)
For intColumnCounter = 1 To intColumnCount
intImageCount = Browser(strBrowserName).
Page(strPageName).WebTable(strTableName).ChildItemCount(intRowCounter, intColumn
Counter, "Image")
If intImageCount > 0 Then
For intImageCounter = 0 To intIm
ageCount-1
strNameName = Browser(st
rBrowserName).Page(strPageName).WebTable(strTableName).ChildItem(intRowCounter,
intColumnCounter, "Image", intImageCounter).GetROProperty("alt")
If strNameName = "Action
:New" Or strNameName = " Approval Status:Pending Approval" Then
blnFlag = "True"
End If
Next
End If
Next
Select Case strCheckFlag
Case "Exist"
If blnFl
ag = "True" Then
Reporter.ReportEvent micPass, "Verifying if the New OR Approval Image is Display
ed or NOT", "The New OR Approval Image is Present"
Else
Reporter.ReportEvent micFail, "Verifying if the New OR Approval Image is Display
ed or NOT", "The New OR Approval Image is NOT Present"
Environment.Value("TestCase_Log") = "False"
Environment.Value("Execution_Log") = "False"
End If
Case "Not Exist"
If blnF
lag = "False" Then
Reporter.ReportEvent micPass, "Verifying if the New OR Approval Image is Display
ed or NOT", "The New OR Approval Image is NOT Present"
Else
Reporter.ReportEvent micFail, "Verifying if the New OR Approval Image is Displa
yed or NOT", "The New OR Approval Image is Present"
Environment.Value("TestCase_Log") = "False"
Environment.Value("Execution_Log") = "False"
End If
End Select
Next
Else
Reporter.ReportEvent micFail,"Verfiying if the Required
Element Exist in the Table to check for the Flag","The Required Element does not
Exist in the Table, hence can' t verify for the Flag"
Environment.Value("TestCase_Log") = "False"
Environment.Value("Execution_Log") = "False"
End If
End Function
'===============================================================================
=======================================================
End Function
'===============================================================================
=============================================================
Public Function GenerateCUSIPNumber()
strCurrentTime = Time
strTime = Split(strCurrentTime,":",-1,1)
strIndTime = Split(strTime(2)," ",-1,1)
strTimeStamp = strTime(0) & strTime(1) & strIndTime(0) &strIndTime(1)
CUSIPNo = "0" & strTimeStamp
intLength = Len(CUSIPNo)
If intLength = 8 Then
CUSIPNo = CUSIPNo & "0"
End If
GenerateCUSIPNumber = CUSIPNo
End Function
'===============================================================================
===================================================
' Name of the Function : ModifiedFlagImageCheck
' Scope of the Function : Public
' Author : Shyam H D
' Description : This function checks for the Modified and the
' Parameters accepted : BrowserName, PageName, Table Name and the Cond
tion "Exist" or Not Exist
' Parameter returned : Null
' Date and / or Version : 22-11-2008,version 1.0
'===============================================================================
===================================================
'===============================================================================
===================================================
' Name of the Function : chkFlagImageinTab
' Scope of the Function : Public
' Author : Shyam H D
' Description : This function checks for the Flag Image that will be dispa
lyed next to the Modified fields.
' Parameters accepted : BrowserName, PageName and Name of the Fields that ar
e modified.
' Parameter returned : Null
' Date and / or Version : 20-10-2008,version 1.0
' Call Statement : 'Call chkFlagImage("MasterFile","Profile - HOLDR
Profile","Detail","US Exchange;Price","Exist")
'===============================================================================
===================================================
Public Function chkFlagImageinTab(strBrowserName, strPageName, strTableName, str
AllCheckVariable, strCheckFlag)
blnImageFlag = "False"
strCheckVariable = Split(strAllCheckVariable, ";", -1, 1)
For intVariable = 0 To UBound(strCheckVariable)
intRowCount = Browser(strBrowserName).Page(strPageName).WebTable(strTabl
eName).RowCount
For intRowCounter = 1 To intRowCount
intColumnCount = Browser(strBrowserName).Page(strPageName).WebTable(
strTableName).ColumnCount(intRowCounter)
For intColumnCounter = 1 To intColumnCount
strGetCellData = Trim(Browser(strBrowserName).Page(strPageName).
WebTable(strTableName).GetCellData(intRowCounter, intColumnCounter))
If strGetCellData = strCheckVariable(intVariable) Then
intImageCount = Browser(strBrowserName).Page(strPageName).We
bTable(strTableName).ChildItemCount(intRowCounter, intColumnCounter, "Image")
If intImageCount > 0 Then
For intImageCounter = 0 To intImageCount - 1
strName = Browser(strBrowserName).Page(strPageName).
WebTable(strTableName).ChildItem(intRowCounter, intColumnCounter, "Image", intIm
ageCounter).GetROProperty("alt")
If strName = "Approval Status:Pending Approval" Then
blnImageFlag = "
True"
Exit For
End If
Next
Select Case strCheckFlag
Case "Exist"
If blnImageFlag = "True"Then
Reporter.ReportEvent micPass, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is Present next to the Field " & strCheckVariab
le(intVariable)
Else
Reporter.ReportEvent micFail, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is NOT Present next to the Field" & strCheckVar
iable(intVariable)
'captureScreenshot
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "False"
End If
Case "Not Exist"
If blnImageFlag = "False" Then
Reporter.ReportEvent micPass, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is NOT Present next to the Field " & strCheckVa
riable(intVariable)
Else
Reporter.ReportEvent micFail, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is Present next to the Field " & strCheckVariab
le(intVariable)
'captureScreenshot
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "False"
End If
End Select
ElseIf intImageCount = 0 Then
Select Case strC
heckFlag
Case "Exist"
If blnImageFlag = "True"Then
Reporter.ReportEvent micPass, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is Present next to the Field " & strCheckVariab
le(intVariable)
Else
Reporter.ReportEvent micFail, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is NOT Present next to the Field" & strCheckVar
iable(intVariable)
'captureScreenshot
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "False"
End If
Case "Not Exist"
If blnImageFlag = "False" Then
Reporter.ReportEvent micPass, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is NOT Present next to the Field " & strCheckVa
riable(intVariable)
Else
Reporter.ReportEvent micFail, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is Present next to the Field " & strCheckVariab
le(intVariable)
'captureScreenshot
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "False"
End If
End Select
End If
Exit For
End If
Next
Next
Next
End Function
'===============================================================================
================================
' Function to Compare the Old values after clicking on the Audit Button
Public Function CompareDROldNewValue(strBrowserName,strPageName,intTableIndexRan
ge)
' Click on the Audit Button
Call click_Image(strBrowserName,strPageName,"Audit")
Wait(5)
For intTableIndexRangeCounter = 1 to intTableIndexRange
blnTestFlag = "False"
intRowCount = Browser("MasterFile").Page("DR Profile").F
rame("lookupFrame").WebTable("index:=" & intTableIndexRangeCounter).RowCount
For intRowCounter = 1 to intRowCount
intColumnCount = Browser("MasterFile").Page("DR
Profile").Frame("lookupFrame").WebTable("index:=" & intTableIndexRangeCounter).C
olumnCount(intRowCounter)
For intColumnCounter = 1 to intColumnCount
strValue = Browser("MasterFile")
.Page("DR Profile").Frame("lookupFrame").WebTable("index:=" & intTableIndexRange
Counter).GetCellData(intRowCounter,intColumnCounter)
If Instr(1,strValue,"CUSIP Chang
e") <> 0 Then
strTabName = "CUSIP Chan
ge"
ElseIf Instr(1,strValue,"Name Ch
ange") Then
strTabName = "Name Chang
e"
ElseIf Instr(1,strValue,"Name Ch
ange") Then
strTabName = "DR Status"
End If
Call chkDROldNewValue(strTabName
,intTableIndexRangeCounter)
blnTestFlag = "True"
Exit For
Next
If blnTestFlag = "True" Then
Exit For
End If
Next
Next
End Function
'===============================================================================
================================================
' Function to Check the Old and the Nedw Vlaue after clicking on Audit Button
Public Function chkDROldNewValue(strTabName,index)
Select Case strTabName
Case "CUSIP Change"
intRowCo
unt = Browser("MasterFile").Page("DR Profile").Frame("lookupFrame").WebTable("in
dex:= "& index).RowCount
For intR
owCounter = 1 to intRowCount
strFieldName = Browser("MasterFile").Page("DR Profile").Frame("lookupFrame").Web
Table("index:= "& index).GetCellData(intRowCounter,1)
If strFieldName = "Type" Then
strNewValue = Browser("MasterFile").Page("DR Profile").Frame("lookupFrame").WebT
able("index:= "& index).GetCellData(intRowCounter,2)
strOldValue = Browser("MasterFile").Page("DR Profile").Frame("lookupFrame").WebT
able("index:= "& index).GetCellData(intRowCounter,3)
If strOldValue = "Primary" And strNewValue = "Primary" Then
Reporter.ReportEvent micPass,"Verfiying the Old and New Values","The Old Value i
s 'Primary' and New Value is 'Primary' in the Field " & strFieldName
Else
Reporter.ReportEvent micFail,"Verfiying the Old and New Values","The Old Value i
s NOT 'Primary' OR New Value is NOT 'Primary' in the Field " & strFieldName
Environment.Value("TestCase_Log") = "False"
Environment.Value("Execution_Log") = "False"
End If
End If
'===============================================================================
=============================================
Public Function DRFlagCheck()
' Select Detail tab
Call click_WebElement("MasterFile","DR Profile","Detail")
Call chkFlagImage("MasterFile","DR Profile","Details","Name","No
t Exist")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Verifying if the Flag is D
isplayed next to the Field 'Name'","The Modified Flag is Not Displayed Next to t
he Field 'Name'"
Else
Reporter.ReportEvent micFail,"Verifying if the Flag is D
isplayed next to the Field 'Name'","The Modified Flag is Displayed Next to the F
ield 'Name'"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Select CUSIP Add / Summary Tab
Call click_WebElement("MasterFile","DR Profile","CUSIPSummary")
Call ModifiedFlagImageCheck("MasterFile","DR Profile","CUSIPSumm
ary","Not Exist")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Verifying if the Flag is d
isplayed in the CUSIP Summary tab or Not","The Flag is Not displayed in the CUSI
P Summary tab"
Else
Reporter.ReportEvent micFail,"Verifying if the Flag is d
isplayed in the CUSIP Summary tab or Not","The Flag is Still displayed in the CU
SIP Summary tab"
'Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Clicking on the Corporate Action Link in DR Profile page -- Na
med Changed and CUSIP Changed Tab
Call click_WebElement("MasterFile","DR Profile","CorporateAction
")
Call chkFlagImageinTab("MasterFile","Corporate Action Data Fix",
"TabName","Name Change;CUSIP Change","Not Exist")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Verifying if the Flag is d
isplayed in the Name Change and CUSIP Change Tab or Not","The Flag is Not displa
yed in the Name Change and CUSIP Change Tab"
Else
Reporter.ReportEvent micFail,"Verifying if the Flag is d
isplayed in the Name Change and CUSIP Change Tab or Not","The Flag is displayed
in the Name Change OR CUSIP Change Tab"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call chkFlagImage("MasterFile","Corporate Action Data Fix","NewV
alue","Name","Not Exist")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Verifying if the Flag is d
isplayed Next to the Fields in the Name Changed Tab","The Flag is Not displayed
in the Fields in the Name Changed Tab"
Else
Reporter.ReportEvent micFail,"Verifying if the Flag is d
isplayed in the Fields in the Name Changed Tab","The Flag is displayed in the Fi
elds in the Name Changed Tab"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call click_WebElement("MasterFile","Corporate Action Data Fix","
CUSIPChange")
Call chkFlagImage("MasterFile","Corporate Action Data Fix","CUSI
P_NewValue","CUSIP;DR ISIN;DR Ticker Symbol;Ratio DRs;Ratio Underlying Shares;DR
Exchange","Not Exist")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Verifying if the Flag is d
isplayed Next to the Fields in the CUSIP Changed Tab","The Flag is Not displayed
in the Fields in the CUSIP Changed Tab"
Else
Reporter.ReportEvent micFail,"Verifying if the Flag is d
isplayed in the Fields in the CUSIP Changed Tab","The Flag is displayed in the F
ields in the CUSIP Changed Tab"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
strNameChangeValue = get_WebList_Value("MasterFile","Corporate A
ction Data Fix","NameChange")
If UCase(Trim(strNameChangeValue)) = UCase(Trim(DataTable.Value(
"IssuerName_Name","DRLifeCycle"))) Then
Reporter.ReportEvent micPass,"Verifying the Name in the
Name Change Field after Clicking on Corporate Action Link","The Name in the Name
Change Field is " & DataTable.Value("IssuerName_Name","DRLifeCycle")
Else
Reporter.ReportEvent micFail,"Verifying the Name in the
Name Change Field after Clicking on Corporate Action Link","The Name in the Name
Change Field is NOT " & DataTable.Value("IssuerName_Name","DRLifeCycle")
Environment.Value("Execution_Log") = "False"
End If
Wait(5)
If DataTable.Value("CheckCorporateActionIssuerFlag","DRLifeCycle
") = "Y" Then
' Click on DR Profile and click on Issuer Name
Call click_WebElement("MasterFile","Corporate Ac
tion Data Fix","DR Profile")
' Click on the Issuer Name
strIssuerName = Browser("MasterFile").Page("DR P
rofile").WebTable("Issuer").GetCellData(1,2)
Browser("MasterFile").Page("DR Profile").WebElem
ent("html tag:=TD","innertext:=" & strIssuerName).Click
If Browser("MasterFile").Dialog("Microsoft Inter
net Explorer").Exist(5) Then
Browser("MasterFile").Dialog("Microsoft
Internet Explorer").WinButton("Cancel").Click
End If
' Click on the Corporate Action link in Issuer
Profile
Call click_WebElement("MasterFile","Issuer Profi
le","CorporateAction")
Call chkFlagImageinTab("MasterFile","Corporate A
ction Data Fix","TabName","Name;Marketing Name","Not Exist")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Verifying
if the Flag is displayed in the Name and Marketing Name Tab or Not","The Flag is
Not displayed in the Name and Marketing Name"
Else
Reporter.ReportEvent micFail,"Verifying
if the Flag is displayed in the Name and Marketing Name Tab or Not","The Flag is
displayed in the Name and Marketing Name"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Call chkFlagImage("MasterFile","Corporate Action
Data Fix","NewValue","Name","Not Exist")
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"Verifying
if the Flag is displayed Next to the Fields in the Name Tab","The Flag is Not di
splayed in the Fields in the Name Tab"
Else
Reporter.ReportEvent micFail,"Verifying
if the Flag is displayed in the Fields in the Name Tab","The Flag is displayed i
n the Fields in the Name Tab"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Wait(5)
' Changing back the Issuer name
'Call set_WebEdit_Value("MasterFile","Corporate
Action Data Fix","Name_NewValue",Environment.Value("Name_OldIssuerName"))
'Call click_Image("MasterFile","Corporate Action
Data Fix","Save")
Wait(2)
' Select Marketing Name Tab
Call click_WebElement("MasterFile","Corporate Ac
tion Data Fix","MarketingName")
Call chkFlagImage("MasterFile","Corporate Action
Data Fix","CUSIP_NewValue","Marketing Name","Not Exist")
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"Verifying
if the Flag is displayed Next to the Fields in the Marketing Name Tab","The Flag
is Not displayed in the Fields in the Marketing Name Tab"
Else
Reporter.ReportEvent micFail,"Verifying
if the Flag is displayed in the Fields in the Marketing Name Tab","The Flag is d
isplayed in the Fields in the Marketing Name Tab"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Wait(5)
'Call set_WebEdit_Value("MasterFile","Corporate
Action Data Fix","Market_NewValue",Environment.Value("Market_OldValue"))
'Call click_Image("MasterFile","Corporate Action
Data Fix","Save")
'Wait(5)
' Click on the Issuer to Navigate to Underlying
Security Profile
Call click_WebElement("MasterFile","Corporate Ac
tion Data Fix","Issuer")
' Click on Underlying Security Search
Call click_WebElement("MasterFile","Issuer Profi
le","UnderlyingSecuritySearch")
Wait(5)
intPos = Browser("MasterFile").Page("Profile - U
nderlying Security").WebTable("UnderlyingSecuritySearch").GetRowWithCellText(Dat
aTable.Value("MarketNewValue","DRLifeCycle"))
If intPos <> -1 Then
Reporter.ReportEvent micPass,"Verifying
if the Underlying Security Name","The Underlying Security Displayed is " & DataT
able("MarketNewValue","DRLifeCycle")
Else
Reporter.ReportEvent micPass,"Verifying
if the Underlying Security Name","The Underlying Security Displayed is NOT " &
DataTable("MarketNewValue","DRLifeCycle")
Environment.Value("Execution_Log") = "Fa
lse"
End If
' Clicking on the DR in Profile Underlying Seacu
rity Search Page
Browser("MasterFile").Page("Profile - Underlying
Security").WebElement("html tag:=TD","innertext:= " & DataTable.Value("MarketNe
wValue","DRLifeCycle"),"index:=1").Click
Wait(5)
' Click On Corporate Action Link in Underlying S
ecurity Profile Page
Call click_WebElement("MasterFile","Underlying S
ecurity Profile","CorporateAction")
' Checking for the Flag
Call chkFlagImageinTab("MasterFile","Corporate A
ction Data Fix","TabName","SEDOL","Not Exist")
If Environment.Value("TestCase_Log") = "True" T
hen
Reporter.ReportEvent micPass,"Verifying
if the Flag is displayed in the SEDOL tab or Not","The Flag is Not displayed in
the SEDOL Tab"
Else
Reporter.ReportEvent micFail, "Verifying
if the Flag is displayed in the SEDOL tab or Not","The Flag is Still Displayed
in the SEDOL Tab"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Call chkFlagImage("MasterFile","Corporate Action
Data Fix","NewValue","Underlying SEDOL","Not Exist")
If Environment.Value("TestCase_Log") = "True" T
hen
Reporter.ReportEvent micPass,"Verifying
if the Flag is displayed Next to the Fields in the SEDOL Tab or NOT","The Flag i
s Not displayed Next to the Fields in the SEDOL Tab"
Else
Reporter.ReportEvent micFail,"Verifying
if the Flag is displayed Next to the Fields in the SEDOL Tab or NOT","The Flag i
s displayed Next to the Fields in the SEDOL Tab"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Wait(2)
' Select ISIN Tab
Call click_WebElement("MasterFile","Corporate Ac
tion Data Fix","ISIN")
Call chkFlagImageinTab("MasterFile","Corporate A
ction Data Fix","TabName","ISIN","Not Exist")
If Environment.Value("TestCase_Log") = "True" T
hen
Reporter.ReportEvent micPass,"Verifying
if the Flag is displayed in the ISIN tab or Not","The Flag is Not displayed in
the ISIN Tab"
Else
Reporter.ReportEvent micFail, "Verifying
if the Flag is displayed in the ISIN tab or Not","The Flag is Still Displayed
in the ISIN Tab"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Call chkFlagImage("MasterFile","Corporate Action
Data Fix","CUSIP_NewValue","Underlying ISIN","Not Exist")
If Environment.Value("TestCase_Log") = "True" Th
en
Reporter.ReportEvent micPass,"Verifying
if the Flag is displayed Next to the Fields in the ISIN Tab or NOT","The Flag is
Not displayed Next to the Fields in the ISIN Tab"
Else
Reporter.ReportEvent micFail,"Verifying
if the Flag is displayed Next to the Fields in the ISIN Tab or NOT","The Flag is
displayed Next to the Fields in the ISIN Tab"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "Fa
lse"
End If
' Select Par/Value Currency tab
Call click_WebElement("MasterFile","Corporate Ac
tion Data Fix","ParValue")
Call chkFlagImageinTab("MasterFile","Corporate A
ction Data Fix","TabName","Par Value/Currency","Not Exist")
If Environment.Value("TestCase_Log") = "True" T
hen
Reporter.ReportEvent micPass,"Verifying
if the Flag is displayed in the Par Value Currency Tab or Not","The Flag is Not
displayed in the Par Value Currency Tab"
Else
Reporter.ReportEvent micFail, "Verifying
if the Flag is displayed in the Par Value Currency Tab or Not","The Flag is St
ill Displayed in the Par Value Currency Tab"
Environment.Value("TestCase_Log") = "Tru
e"
Environment.Value("Execution_Log") = "Fa
lse"
End If
Call chkFlagImage("MasterFile","Corporate Action
Data Fix","Ratio_NewValue","Par Value;Currency","Not Exist")
If Environment.Value("TestCase_Log") = "True" T
hen
Reporter.ReportEvent micPass,"Verifying
if the Flag is displayed Next to the Fields in the Par Value Currency Tab or NOT
","The Flag is Not displayed Next to the Fields in the IPar Value Currency Tab"
Else
Reporter.ReportEvent micFail,"Verifying
if the Flag is displayed Next to the Fields in the Par Value Currency Tab or NOT
","The Flag is displayed Next to the Fields in the Par Value Currency Tab"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "Fa
lse"
End If
End If
' If Environment.Value("TestCase_Log") = "True" Then
' Reporter.ReportEvent micPass,"Verifying if the Flag is d
isplayed in the SEDOL, ISIN and Par Valu/Currency tab or Not","The Flag is Not
displayed in the SEDOL, ISIN and Par Valu/Currency tab"
' Else
' Reporter.ReportEvent micFail,"Verifying if the Flag is d
isplayed in the Name and Marketing Name Tab or Not","The Flag is displayed in th
e SEDOL or ISIN or Par Valu/Currency tab"
' 'Environment.Value("TestCase_Log") = "True"
' Environment.Value("Execution_Log") = "False"
' End If
End Function
'===============================================================================
============================
' Function to Create a New DR with CUSIP
Public Function CreateNewDR(strBrowserName,strPageName,strDRPageName,strCUSIPPag
eName)
' Select Master File Application
Call click_WebElement("MasterFile","Depositary Receipt Division'
s","MasterFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("Menu
Path","DRLifeCycle"))
Call set_WebEdit_Value("MasterFile","Profile - DR Search","Issue
rName",DataTable.Value("IssuerName","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
If Browser(strBrowserName).Page(strPageName).Image("NewDR").Exis
t(2) then
Call click_Image(strBrowserName,strPageName,"NewDR")
End if
'Fill the details of the new DR to be created
Call Select_Combo_Value("CreateNewDR","CreateNewDR","Sponsored",
DataTable.Value("Sponsored","DRLifeCycle"))
Call click_Image("CreateNewDR","CreateNewDR","Depositary")
Call operation_on_FrameObjects_WithName("CreateNewDR","CreateNew
DR","lookupFrame","WebCheckBox",DataTable.value("NewDRDepositary","DRLifeCycle")
,"")
Call operation_on_FrameObjects_WithName("CreateNewDR","CreateNew
DR","lookupFrame","WebButton"," Ok ","")
Call Select_Combo_Value("CreateNewDR","CreateNewDR","Type",DataT
able.Value("NewDRType","DRLifeCycle"))
Call click_WebButton("CreateNewDR","CreateNewDR","Ok")
strCurrentTime = Time
strTime = Split(strCurrentTime,":",-1,1)
strIndTime = Split(strTime(2)," ",-1,1)
strTimeStamp = strTime(0) & strTime(1) & strIndTime(0) &strIndTi
me(1)
CUSIPNo = "0" & strTimeStamp
If Len(CUSIPNo) = 8 Then
CUSIPNo = CUSIPNo & "0"
End If
DRName = "QTPDR_" & strTimeStamp
DRName= Replace(DRName," ","")
DataTable.Value("DRName","DRLifeCycle") = DRName
DataTable.Value("CUSIP", "DRLifeCycle") = CUSIPNo
strVar1 = Environment("TestDir")
strIndVar1 = Split(strVar1,"\",-1,1)
strBound = UBound(strIndVar1)
strAllPath1 =""
For intCounters = 0 to strBound - 1
strAllPath1 = strAllPath1 & strIndVar1(intCounte
rs) &"\"
Next
strPath1 = Trim(strPath1)
strDataPath1 = strAllPath1 & "DataTables\"
DataTable.ExportSheet strDataPath1 & "DRLifeCycle.xls","DRLifeCy
cle"
DataTable.ImportSheet strDataPath1 & "DRLifeCycle.xls","DRLifeCycle","DR
LifeCycle"
'Fill the details in the Details tab for DR
Call set_WebEdit_Value(strBrowserName,strDRPageName,"Details_Nam
e",DataTable.Value("DRName","DRLifeCycle"))
Call Select_Combo_Value(strBrowserName,strDRPageName,"SecurityDe
scription",DataTable.Value("SecurityDescription","DRLifeCycle"))
If DataTable.Value("NewDREffectiveDate","DRLifeCycle") <> "" Th
en
Call click_Image(strBrowserName,strDRPageName,"Details_E
ffectiveDate")
Call SetDate(strBrowserName,strDRPageName,DataTable.Valu
e("NewDREffectiveDate","DRLifeCycle"))
End If
If Browser(strBrowserName).Dialog("Microsoft Internet Explorer")
.Exist(2) Then
Browser(strBrowserName).Dialog("Microsoft Internet Explo
rer").WinButton("OK").click
End If
strFirstFilerValue = get_WebList_Value(strBrowserName,strDRPageN
ame,"FirstFiler")
If DataTable.Value("Sponsored","DRLifeCycle") = "U" Then
If strFirstFilerValue = "#0" Then
Call Select_Combo_Value(strBrowserName,strDRPage
Name,"FirstFiler",DataTable.Value("NewDRDepositary", "DRLifeCycle"))
End If
End If
Wait(5)
'Call set_WebEdit_Value(strBrowserName,strDRPageName,"Comments","This is
for a testing purpose. This has been created by the ADR Automation Team")
Call click_Image(strBrowserName,strDRPageName,"Save")
Wait(5)
'Select the CUSIP Add tab and Click on Add button for Creating a
New CUSIP
Call click_WebElement(strBrowserName,strDRPageName,"CUSIPSummary
")
Call click_WebButton(strBrowserName,strDRPageName,"Add")
'Set the CUSIP details
FinalRowCount = Browser("MasterFile").Page("DR Profile").WebTable("CUSIP
Summary").RowCount
Browser("MasterFile").Page("DR Profile").WebTable("CUSIPSummary"
).ChildItem(FinalRowCount,1,"WebList","0").Select DataTable.Value("CUSIP_Type","
DRLifeCycle")
If Browser("MasterFile").Page("DR Profile").Image("NewCUSIP").Ex
ist(5) Then
Browser("MasterFile").Page("DR Profile").Image("NewCUSIP
").Click
End If
strCurrentTime = Time
strCurrentDate = Date
strDate = Split(strCurrentDate,"/" ,-1,1)
strTime = Split(strCurrentTime,":",-1,1)
strDateTimeStamp = strDate(0) &strDate(1)&strDate(2) & " "& str
Time(0) & strTime(1) & strTime(2)
strCUSIPDefaultName = get_WebEdit_Value(strBrowserName,strCUSIPP
ageName,"CUSIPName")
strFirstChar = Mid(strCUSIPDefaultName,1,1)
If Asc(strFirstChar) = 94 or Asc(strFirstChar) = 38 Then
CUSIPNames = strFirstChar & "QTPCUSIP_" & strDateTimeSta
mp
SelectCUSIPNames = "\"& strFirstChar &"\"&"QTPCUSIP_" &
strDateTimeStamp
CUSIPName = Replace(CUSIPNames," ","")
SelectCUSIPName = Replace(SelectCUSIPNames," ","")
DataTable.Value("CUSIPName", "DRLifeCycle") = CUSIPName
DataTable.Value("SelectCUSIPName", "DRLifeCycle") = Sele
ctCUSIPName
Else
CUSIPNames = "QTPCUSIP_" & strDateTimeStamp
CUSIPName = Replace(CUSIPNames," ","")
SelectCUSIPName = Replace(SelectCUSIPNames," ","")
DataTable.Value("CUSIPName", "DRLifeCycle") = CUSIPName
DataTable.Value("SelectCUSIPName", "DRLifeCycle") = CUSI
PName
End If
DataTable.ExportSheet strDataPath1 & "DRLifeCycle.xls","DRLifeCycle"
DataTable.ImportSheet strDataPath1 & "MasterFileProfile.xls","DRLifeCycl
e","DRLifeCycle"
' Entering the NEW CUSIP Details
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"CUSIPNam
e",DataTable.Value("CUSIPName","DRLifeCycle"))
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"RatioDRs",DataTa
ble.Value("RatioDRs","DRLifeCycle"))
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"RatioUnd
erlyingShares",DataTable.Value("RatioUnderlyingShares","DRLifeCycle"))
' Selecting an Underlying Security
Call SelectImage(strBrowserName,strCUSIPPageName,"Detail","Under
lying Security","info.gif")
Call SelectValueinFrame(strBrowserName,strCUSIPPageName,"lookupF
rame","Exchange")
' Selecting Common Depository
If DataTable.Value("NewDRDepositary","DRLifeCycle") = "BNY" Then
Call SelectImage(strBrowserName,strCUSIPPageName,"Detail
","Common Depository","info.gif")
Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Name")
End If
' If Browser("MasterFile").Page("CUSIP Profile").Image("Underlyin
gSecurity").Exist(2) Then
' Call click_Image(strBrowserName,strCUSIPPageName,"Underl
yingSecurity")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Exchange")
' Wait(2)
' Call click_Image(strBrowserName,strCUSIPPageName,"Warran
tAgent")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Name")
' Else
' Call click_Image(strBrowserName,strCUSIPPageName,"Warran
tAgent")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Exchange")
' End If
' Selecting the DR Exchange
Call SelectImage(strBrowserName,strCUSIPPageName,"Detail","DR Ex
change","info.gif")
'Call click_Image(strBrowserName,strCUSIPPageName,"DRExchange")
Call SelectDRExchange(strBrowserName,strCUSIPPageName,"Exchange"
,DataTable.Value("DRExchange","DRLifeCycle"))
' Entering the DR Ticker Symbol
strDRTickerSymbol =CreateAlphanumericString(5)
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"DRTicker
Symbol",strDRTickerSymbol)
' Entering DR SEDOL
If DataTable.Value("NewDRType","DRLifeCycle") = "Reg. S" Or Data
Table.Value("NewDRType","DRLifeCycle") = "144A" Then
strDRSEDOL =CreateAlphanumericString(7)
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"
DRSEDOL",strDRSEDOL)
End If
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"CUSIP",D
ataTable.Value("CUSIP","DRLifeCycle"))
If Browser(strBrowserName).Dialog("Microsoft Internet Explorer")
.Exist(2) Then
Browser(strBrowserName).Dialog("Microsoft Internet Explo
rer").WinButton("OK").Click
End If
Wait(5)
Call click_Image(strBrowserName,strCUSIPPageName,"Save")
Wait(10)
' Clicking on the DR and changing the DR Status to Effective
strValues = Browser(strBrowserName).Page(strCUSIPPageName).WebTa
ble("DR").GetCellData(1,2)
Browser(strBrowserName).Page(strCUSIPPageName).WebElement("html
tag:=TD","innertext:=" & strValues,"index:=0","class:=tabSelected").Click
Wait(5)
If Browser("MasterFile").Page("DR Profile").WebEdit("Details_SU"
).Exist(5) Then
strSUValue = Browser("MasterFile").Page("DR Profile").We
bEdit("Details_SU").GetROProperty("value")
Environment.Value("SponserUnsponser") = strSUValue
End If
'===============================================================================
===================================
Public Function SelectExistingCUSIP()
Call click_Image("MasterFile","DR Profile","CUSIPLookup")
Wait(5)
intRowCount = Browser("MasterFile").Page("DR Profile").Frame("lookupFram
e").WebTable("DR").RowCount
For intRowCounter = 2 to intRowCount
strDRFlag = Browser("MasterFile").Page("DR Profile").Frame("look
upFrame").WebTable("DR").GetCellData(intRowCounter,1)
If strDRFlag = "Y" Then
strCUSIP = Browser("MasterFile").Page("DR Profile").Fram
e("lookupFrame").WebTable("DR").GetCellData(intRowCounter,2)
If Trim(UCase(strCUSIP)) = Trim(UCase(DataTable.Value("CUSIPName","DR
LifeCycle"))) Then
Browser("MasterFile").Page("DR Profile").Frame("
lookupFrame").WebElement("html tag:=TD","innertext:=" & strDRFlag).Click
Wait(2)
Exit For
End If
End If
Next
End Function
'===============================================================================
===================================================
' Name of the Function : ApprovalFunction_DR
' Scope of the Function : Public
' Author : Shyam H D
' Description : This function is used to Approve or Reject the
Changes madescheck iif the WebList is a Mandatory Field or Not.
' Parameters accepted : Application Name, Module Name, Table Header Va
lues, Modified or Created Element Name, Approval Comment, Approval Condition
' Parameter returned : Nill
' Date and / or Version : 22-11-2008,version 1.0
'Function Call : Call ApprovalFunction("MasterFile","CUSIP Prof
ile","Name;CUSIP;Last User Updated;Last Updated",DataTable.Value("CUSIPName","CU
SIP"),"Approved")
'===============================================================================
===================================================
'===============================================================================
===================================================
' Name of the Function : SelectValueinTable
' Scope of the Function : Public
' Author : Shyam H D
' Description : This function is used to Select a Val;ue from
the WebTable.
' Parameters accepted : BrowserName, PageName, Table Name and the Valu
e that has to be Selected from Table
' Parameter returned : Nill
' Date and / or Version : 22-11-2008,version 1.0
'===============================================================================
===================================================
'===============================================================================
=====================================================
Public Function CreateBifurcatedDR_DontDelete(strBrowserName,strPageName,strDRPa
geName,strCUSIPPageName)
strVar = Environment("TestDir")
strIndVar = Split(strVar,"\",-1,1)
strBound = UBound(strIndVar)
strAllPath =""
For intCounter = 0 to strBound - 1
strAllPath = strAllPath & strIndVar(intCounter)
&"\"
Next
strPath = Trim(strPath)
strDataPaths = strAllPath & "DataTables\"
' Select Master File Application
Call click_WebElement("MasterFile","Depositary Receipt Division'
s","MasterFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("Menu
Path","DRLifeCycle"))
Call set_WebEdit_Value("MasterFile","Profile - DR Search","Issue
rName",DataTable.Value("IssuerName","DRLifeCycle"))
Call click_Image("MasterFile","Profile - DR Search","Search")
If Browser(strBrowserName).Page(strPageName).Image("NewDR").Exis
t(2) then
Call click_Image(strBrowserName,strPageName,"NewDR")
End if
'Fill the details of the new DR to be created
Call Select_Combo_Value("CreateNewDR","CreateNewDR","Sponsored",
DataTable.Value("Sponsored","DRLifeCycle"))
Call click_Image("CreateNewDR","CreateNewDR","Depositary")
Call operation_on_FrameObjects_WithName("CreateNewDR","CreateNew
DR","lookupFrame","WebCheckBox",DataTable.value("NewDRDepositary","DRLifeCycle")
,"")
Call operation_on_FrameObjects_WithName("CreateNewDR","CreateNew
DR","lookupFrame","WebButton"," Ok ","")
Call Select_Combo_Value("CreateNewDR","CreateNewDR","Type",DataT
able.Value("NewDRType","DRLifeCycle"))
Call click_WebButton("CreateNewDR","CreateNewDR","Ok")
strCurrentTime = Time
strTime = Split(strCurrentTime,":",-1,1)
strIndTime = Split(strTime(2)," ",-1,1)
strTimeStamp = strTime(0) & strTime(1) & strIndTime(0) &strIndTi
me(1)
CUSIPNo = "0" & strTimeStamp
If Len(CUSIPNo) = 8 Then
CUSIPNo = CUSIPNo & "0"
End If
Environment.Value("CUSIPNum144A") = CUSIPNo
DRName1 = "QTPDR_" & strTimeStamp &"_144A"
DRName1= Replace(DRName1," ","")
DRName2 = "QTPDR_" & strTimeStamp &"_RegS"
DRName2= Replace(DRName2," ","")
Environment.Value("DR144A") = DRName1
Environment.Value("DRRegS") = DRName2
'Fill the details in the Details tab for DR
Call set_WebEdit_Value(strBrowserName,strDRPageName,"Details_Nam
e",Environment.Value("DR144A"))
Call Select_Combo_Value(strBrowserName,strDRPageName,"SecurityDe
scription",DataTable.Value("SecurityDescription","DRLifeCycle"))
If DataTable.Value("NewDREffectiveDate","DRLifeCycle") <> "" Th
en
Call click_Image(strBrowserName,strDRPageName,"Details_E
ffectiveDate")
Call SetDate(strBrowserName,strDRPageName,DataTable.Valu
e("NewDREffectiveDate","DRLifeCycle"))
End If
If Browser(strBrowserName).Dialog("Microsoft Internet Explorer")
.Exist(2) Then
Browser(strBrowserName).Dialog("Microsoft Internet Explo
rer").WinButton("OK").click
End If
If Browser(strBrowserName).Dialog("Microsoft Internet Explorer"
).Exist(2) Then
Browser(strBrowserName).Dialog("Microsoft Internet Explo
rer").WinButton("OK").click
End If
Call click_Image(strBrowserName,strDRPageName,"Save")
'Select the CUSIP Add tab and Click on Add button for Creating a
New CUSIP
Call click_WebElement(strBrowserName,strDRPageName,"CUSIPSummary
")
Call click_WebButton(strBrowserName,strDRPageName,"Add")
'Set the CUSIP details
FinalRowCount = Browser("MasterFile").Page("DR Profile").WebTable("CUSIP
Summary").RowCount
Browser("MasterFile").Page("DR Profile").WebTable("CUSIPSummary"
).ChildItem(FinalRowCount,1,"WebList","0").Select DataTable.Value("CUSIP_Type","
DRLifeCycle")
If Browser("MasterFile").Page("DR Profile").Image("NewCUSIP").Ex
ist(5) Then
Browser("MasterFile").Page("DR Profile").Image("NewCUSIP
").Click
End If
strCurrentTime = Time
strCurrentDate = Date
strDate = Split(strCurrentDate,"/" ,-1,1)
strTime = Split(strCurrentTime,":",-1,1)
strDateTimeStamp = strDate(0) &strDate(1)&strDate(2) & " "& str
Time(0) & strTime(1) & strTime(2)
strCUSIPDefaultName = get_WebEdit_Value(strBrowserName,strCUSIPP
ageName,"CUSIPName")
strFirstChar = Mid(strCUSIPDefaultName,1,1)
If Asc(strFirstChar) = 94 or Asc(strFirstChar) = 38 Then
strFirstChar = Replace(strFirstChar," ","")
CUSIPNames = strFirstChar & "QTPCUSIP_" & strDateTimeSta
mp
SelectCUSIPNames = "\"& strFirstChar &"\"&"QTPCUSIP_" &
strDateTimeStamp
CUSIPName = Replace(CUSIPNames," ","")
SelectCUSIPName = Replace(SelectCUSIPNames," ","")
Environment.Value("CUSIP144A") = CUSIPName
Environment.Value("SelectCUSIP144A") = SelectCUSIPName
DataTable.Value("SelectCUSIPName","DRLifeCycle") = Selec
tCUSIPName
Else
CUSIPNames = "QTPCUSIP_" & strDateTimeStamp
CUSIPName = Replace(CUSIPNames," ","")
Environment.Value("CUSIP144A") = CUSIPName
Environment.Value("SelectCUSIP144A") = CUSIPName
'DataTable.Value("SelectCUSIPName","DRLifeCycle") = CUSI
PName
End If
DataTable.ExportSheet strDataPaths & "DRLifeCycle.xls","DRLifeCy
cle"
DataTable.ImportSheet strDataPaths & "DRLifeCycle.xls","DRLifeCy
cle","DRLifeCycle"
' Entering the NEW CUSIP Details
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"CUSIPNam
e",Environment.Value("CUSIP144A"))
'Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"BriefNa
me",DataTable.Value("BriefName","DRLifeCycle"))
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"RatioDRs
",DataTable.Value("RatioDRs","DRLifeCycle"))
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"RatioUnd
erlyingShares",DataTable.Value("RatioUnderlyingShares","DRLifeCycle"))
Wait(5)
If Browser("MasterFile").Page("CUSIP Profile").Image("Underlyin
gSecurity").Exist(5) Then
Call click_Image(strBrowserName,strCUSIPPageName,"Under
lyingSecurity")
Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Exchange")
Wait(2)
Call click_Image(strBrowserName,strCUSIPPageName,"Warran
tAgent")
Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Name")
Else
Call click_Image(strBrowserName,strCUSIPPageName,"Warran
tAgent")
Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Exchange")
End If
' Call click_Image(strBrowserName,strCUSIPPageName,"WarrantAgent")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,"lookupF
rame","Name")
' Need to Enter DR Exchange
Call click_Image(strBrowserName,strCUSIPPageName,"DRExchange")
Call SelectDRExchange(strBrowserName,strCUSIPPageName,"Exchange"
,DataTable.Value("DRExchange","DRLifeCycle"))
' ' Selecting an Underlying Security
' Call click_Image(strBrowserName,strCUSIPPageName,"UnderlyingSecu
rity")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,"lookupF
rame","Exchange")
' Entering the CUSIP Number
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"CUSIP",E
nvironment.Value("CUSIPNum144A"))
If Browser(strBrowserName).Dialog("Microsoft Internet Explorer")
.Exist(2) Then
Browser(strBrowserName).Dialog("Microsoft Internet Explo
rer").WinButton("OK").Click
End If
' Entering DR Ticker Symbol
strDRTickerSymbol =CreateAlphanumericString(5)
Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"DRTicker
Symbol",strDRTickerSymbol)
' Save the Changes made to the CUSIP.
Call click_Image(strBrowserName,strCUSIPPageName,"Save")
Wait(10)
strDRAppNames = Browser("MasterFile").Page("CUSIP Profile").WebT
able("DR").GetCellData(1,2)
Browser("MasterFile").Page("CUSIP Profile").WebElement("html tag
:=TD","innertext:="& strDRAppNames,"class:=tabselected").Click
' Filling the DR Documentation if the Flag is set to "Y"
If DataTable.Value("NewDRDepositary","DRLifeCycle") = "BNY" Then
' Filling the SECFiling Tab
Call DRFillSECFiling()
Wait(2)
Call DRDocumentation()
Wait(5)
End If
' Clicking on the DR and changing the DR Status to Effective
Call Select_Combo_Value(strBrowserName, strDRPageName, "Details_
Status","Effective")
Call click_Image(strBrowserName,strDRPageName,"Save")
' Logout from Application and Approve the Newly Created CUSIP a
nd DR Name
Call logoutfromApp(strBrowserName, strDRPageName)
' Login again with Approval ID
Call invoke_URL(strBrowserName,"Login Page",Environment.Value("A
ppURL"))
Call login(strBrowserName,"Login Page","Approver","MFLogin")
' Approving the Newly created CUSIP and DR Documentation and DR
Profile.
'Call ApprovalFunction_DR("MasterFile","CUSIP Profile","Name;CUS
IP;Last User Updated;Last Updated",Environment.Value("CUSIP144A"),"Approved the
Changes Made","Approved","Pending Approval")
' If DataTable.Value("NewDRDepositary","DRLifeCycle") = "BNY" The
n
' Call ApprovalFunction_DR("MasterFile","DR Documentation"
,"",Environment.Value("DR144A"),"Approved the Changes Made","Approved","Pending
Approval")
' End If
' Call ApprovalFunction_DR("MasterFile","DR Profile","",Environment.Value
("DR144A"),"Approved the Changes Made","Approved","Pending Approval")
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
' Login again with Approval ID
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","User","MFLogin")
' Click on Master File Link and Select the Profile DR Menu
Call click_WebElement("MasterFile","Depositary Receipt Division'
s","MasterFile")
Call select_Menu("MasterFile","MasterFile",DataTable.Value("Menu
Path","DRLifeCycle"))
'Search for the Newly Created DR
Call set_WebEdit_Value("MasterFile","Profile - DR Search","IssuerName",D
ataTable.Value("IssuerName","DRLifeCycle"))
Call set_WebEdit_Value("MasterFile","Profile - DR Search","DRNam
e",Environment.Value("DR144A"))
Call click_Image("MasterFile","Profile - DR Search","Search")
Wait(5)
Browser("MasterFile").Page("Profile - DR Search").WebElement("ht
ml tag:=TD","innertext:=" & Environment.Value("DR144A")).Click
Wait(5)
' Select the DR Life Cycle WebElement again and Select Bifurcate
d DR Radiobutton
Wait(5)
Call click_WebElement(strBrowserName,strDRPageName,"DRLifeCycle"
)
Wait(2)
If Browser("MasterFile").Dialog("Microsoft Internet Explorer").E
xist(5) Then
Browser("MasterFile").Dialog("Microsoft Internet Explore
r").WinButton("Cancel").Click
End If
' Selecting the Bifurcated Radiobutton
strBifurcatedRadioName = "bfrc"
Browser("DR Lifecycle").Page("DR Lifecycle").WebRadioGroup("Upgr
ade").Select strBifurcatedRadioName
Wait(2)
Call click_WebButton("DR Lifecycle","DR Lifecycle","CreateNewDR"
)
' strCurrentTime = Time
' strTime = Split(strCurrentTime,":",-1,1)
' strIndTime = Split(strTime(2)," ",-1,1)
' strTimeStamp = strTime(0) & strTime(1) & strIndTime(0) &strIndTi
me(1)
' CUSIPNo = "0" & strTimeStamp
' If Len(CUSIPNo) = 8 Then
' CUSIPNo = "CUSIPNo" & "0"
' End If
'
' Environment.Value("CUSIPNumRegS") = CUSIPNo
' Fill the details in the Details tab for DR
Call set_WebEdit_Value(strBrowserName,strDRPageName,"Details_Nam
e",Environment.Value("DRRegS"))
Call Select_Combo_Value(strBrowserName,strDRPageName,"SecurityDe
scription",DataTable.Value("SecurityDescription","DRLifeCycle"))
' If DataTable.Value("NewDREffectiveDate","DRLifeCycle") <> "" Th
en
' Call click_Image(strBrowserName,strDRPageName,"Details_E
ffectiveDate")
' Call SetDate(strBrowserName,strDRPageName,DataTable.Valu
e("NewDREffectiveDate","DRLifeCycle"))
' End If
Call click_Image(strBrowserName,strDRPageName,"Save")
'Select the CUSIP Add tab and Click on Add button for Creating a
New CUSIP
Call click_WebElement(strBrowserName,strDRPageName,"CUSIPSummary
")
Call click_WebButton(strBrowserName,strDRPageName,"Add")
'Set the CUSIP details
FinalRowCount = Browser("MasterFile").Page("DR Profile").WebTable("CUSIP
Summary").RowCount
Browser("MasterFile").Page("DR Profile").WebTable("CUSIPSummary"
).ChildItem(FinalRowCount,1,"WebList","0").Select DataTable.Value("CUSIP_Type","
DRLifeCycle")
If Browser("MasterFile").Page("DR Profile").Image("CUSIPLookup")
.Exist(5) Then
Browser("MasterFile").Page("DR Profile").Image("CUSIPLoo
kup").Click
End If
' Selecting an Existing CUSIP
Call SelectExistingCUSIP()
Call click_Image("MasterFile","DR Profile","Save")
' Filling the DR Documentation Details
If DataTable.Value("DRDocumentationRequired","DRLifeCycle") = "
Y" Then
' Filling the SEC Filing Tab
Call DRFillSECFiling()
Wait(5)
' Select Detail Tab
Call click_WebElement("MasterFile","DR Profile","Detail"
)
Wait(5)
Call DRDocumentation()
End If
' Clicking on Save
Call click_Image(strBrowserName,strDRPageName,"Save")
' If Browser("MasterFile").Page("DR Profile").Image("NewCUSIP").Ex
ist(5) Then
' Browser("MasterFile").Page("DR Profile").Image("NewCUSIP
").Click
' End If
'
' Wait(5)
' strCurrentTime = Time
' strCurrentDate = Date
' strDate = Split(strCurrentDate,"/" ,-1,1)
' strTime = Split(strCurrentTime,":",-1,1)
' strDateTimeStamp = strDate(0) &strDate(1)&strDate(2) & " "& str
Time(0) & strTime(1) & strTime(2)
'
' Wait(5)
' strCUSIPDefaultName = get_WebEdit_Value(strBrowserName,strCUSIPP
ageName,"CUSIPName")
' strFirstChar = Mid(strCUSIPDefaultName,1,1)
' If Asc(strFirstChar) = 94 or Asc(strFirstChar) = 38 Then
' CUSIPNames = strFirstChar & "QTPCUSIP_" & strDateTimeSta
mp
' SelectCUSIPNames = "\"& strFirstChar &"\"&"QTPCUSIP" & s
trDateTimeStamp
' CUSIPName = Replace(CUSIPNames," ","")
' SelectCUSIPName = Replace(SelectCUSIPNames," ","")
' Environment.Value("CUSIPRegS") = CUSIPName
' Environment.Value("SelectCUSIPRegS") = SelectCUSIPName
' 'DataTable.Value("SelectCUSIPName") = SelectCUSIPName
' Else
' CUSIPNames = "QTPCUSIP_" & strDateTimeStamp
' CUSIPName1 = Replace(CUSIPNames," ","")
' Environment.Value("CUSIPRegS") = CUSIPName1
' Environment.Value("SelectCUSIPRegS") = CUSIPName1
' End If
'
' DataTable.ExportSheet strDataPaths & "DRLifeCycle.xls","DRLifeCy
cle"
' DataTable.ImportSheet strDataPaths & "DRLifeCycle.xls","DRLifeCy
cle","DRLifeCycle"
'
' ' Entering the NEW CUSIP Details
' Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"CUSIPNam
e",Environment.Value("CUSIPRegS"))
' ==== Not requird
'Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"BriefNa
me",DataTable.Value("BriefName","DRLifeCycle"))
'Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"RatioDR
s",DataTable.Value("RatioDRs","DRLifeCycle"))
'Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"RatioUn
derlyingShares",DataTable.Value("RatioUnderlyingShares","DRLifeCycle"))
' Call click_Image(strBrowserName,strCUSIPPageName,"WarrantAgent")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,"lookupF
rame","Exchange")
' Wait(5)
' If Browser("MasterFile").Page("CUSIP Profile").Image("Underlyin
gSecurity").Exist(5) Then
' Call click_Image(strBrowserName,strCUSIPPageName,"Under
lyingSecurity")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Exchange")
' Wait(2)
' Call click_Image(strBrowserName,strCUSIPPageName,"Warran
tAgent")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Name")
' Else
' Call click_Image(strBrowserName,strCUSIPPageName,"Warran
tAgent")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,
"lookupFrame","Exchange")
' End If
' Selecting the DR Exchange
' Call click_Image(strBrowserName,strCUSIPPageName,"DRExchange")
' Call SelectDRExchange(strBrowserName,strCUSIPPageName,"Exchange"
,DataTable.Value("DRExchange","DRLifeCycle"))
'
' ' Selecting an Underlying Security
' Call click_Image(strBrowserName,strCUSIPPageName,"UnderlyingSecu
rity")
' Call SelectValueinFrame(strBrowserName,strCUSIPPageName,"lookupF
rame","Exchange")
' Wait(2)
' Entering the DR Ticker Symbol
' strDRTickerSymbol =CreateAlphanumericString(5)
' Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"DRTicker
Symbol",strDRTickerSymbol)
' Call set_WebEdit_Value(strBrowserName,strCUSIPPageName,"CUSIP",E
nvironment.Value("CUSIPNumRegS"))
' If Browser(strBrowserName).Dialog("Microsoft Internet Explorer")
.Exist(2) Then
' Browser(strBrowserName).Dialog("Microsoft Internet Explo
rer").WinButton("OK").Click
' End If
' Wait(5)
' Call click_Image(strBrowserName,strCUSIPPageName,"Save")
' Wait(10)
'
' ' Clicking on the DR
' strDRNames = Browser("MasterFile").Page("CUSIP Profile").WebTabl
e("DR").GetCellData(1,2)
' Browser("MasterFile").Page("CUSIP Profile").WebElement("html tag
:=TD","innertext=:="& strDRNames).Click
'
' ' Filling the DR Documentation Details
' If DataTable.Value("DRDocumentationRequired","DRLifeCycle") = "
Y" Then
' ' Filling the SEC Filing Tab
' Call DRFillSECFiling()
' Wait(5)
'
' ' Select Detail Tab
' Call click_WebElement("MasterFile","DR Profile","Detail"
)
' Wait(5)
' Call DRDocumentation()
' End If
'
' ' Clicking on the DR and changing the DR Status to Effective
'' Call Select_Combo_Value(strBrowserName, strDRPageName, "Details_
Status","Effective")
' Call click_Image(strBrowserName,strDRPageName,"Save")
' Logout from Application and Approve the Newly Created CUSIP and DR Nam
e
Call logoutfromApp(strBrowserName, strDRPageName)
' Login again with Approval ID
Call invoke_URL("MasterFile","Login Page",Environment.Value("App
URL"))
Call login("MasterFile","Login Page","Approver","MFLogin")
' Approving the Newly created CUSIP and DR.
'Approving the Newly created CUSIP and DR Documentation and DR
Profile.
' Call ApprovalFunction_DR("MasterFile","CUSIP Profile","Name;CUSI
P;Last User Updated;Last Updated",Environment.Value("CUSIP144A"),"Approved the C
hanges Made","Approved","Pending Approval")
If DataTable.Value("NewDRDepositary","DRLifeCycle") = "BNY" The
n
Call ApprovalFunction_DR("MasterFile","DR Documentation"
,"DR Name;DR Type;S/U;Origin;DR Structure;Last User Updated;Last Updated",Enviro
nment.Value("DR144A"),"Approved the Changes Made","Approved","Pending Approval")
End If
Call ApprovalFunction_DR("MasterFile","DR Profile","Name;Type;Depositary
;S/U;Origin;Structure;Last User Updated;Last Updated",Environment.Value("DR144A"
),"Approved the Changes Made","Approved","Pending Approval")
'Call ApprovalFunction_DR("MasterFile","CUSIP Profile","Name;CUSIP;Last
User Updated;Last Updated",Environment.Value("SelectCUSIPRegS"),"Approved the Ch
anges Made","Approved","Pending Approval")
If DataTable.Value("NewDRDepositary","DRLifeCycle") = "BNY" Then
Call ApprovalFunction_DR("MasterFile","DR Documentation"
,"DR Name;DR Type;S/U;Origin;DR Structure;Last User Updated;Last Updated",Enviro
nment.Value("DRRegS"),"Approved the Changes Made","Approved","Pending Approval")
End If
Call ApprovalFunction_DR("MasterFile","DR Profile","Name;Type;Depositary
;S/U;Origin;Structure;Last User Updated;Last Updated",Environment.Value("DRRegS"
),"Approved","Approved","Pending Approval")
Call logoutfromApp("MasterFile","Depositary Receipt Division's")
End Function
'===============================================================================
=================================
'===============================================================================
=================================================================
Public Function DRDocumentation()
Wait(10)
Call click_WebElement("MasterFile","DR Profile","DRDocum
entation")
If Browser("MasterFile").Dialog("Microsoft Internet Expl
orer").Exist(5) Then
strText = Browser("MasterFile").Dialog("Microsof
t Internet Explorer").Static("MessageText").GetROProperty("text")
strReqValue = "Please click OK to Save Changes (
if any) or click Cancel to Continue"
If strText = strReqValue Then
Reporter.ReportEvent micPass,"Step 21: V
erifying the Message in the Dialog","The Message displayed in the Dialog is " &
strText
Else
Reporter.ReportEvent micFail,"Step 21: V
erifying the Message in the Dialog","The Message displayed in the Dialog is NOT
" & strText
Environment.Value("Execution_Log") = "Fa
lse"
End If
Browser("MasterFile").Dialog("Microsoft Internet
Explorer").WinButton("Cancel").Click
End If
If Browser("MasterFile").Page("DR Profile").Exist(5) The
n
Call click_WebElement("MasterFile","DR Profile",
"DRDocumentation")
If Browser("MasterFile").Dialog("Microsoft Inter
net Explorer").Exist(5) Then
strText = Browser("MasterFile").Dialog("
Microsoft Internet Explorer").Static("MessageText").GetROProperty("text")
strReqValue = "Please click OK to Save C
hanges (if any) or click Cancel to Continue"
If strText = strReqValue Then
Reporter.ReportEvent micPass,"St
ep 21: Verifying the Message in the Dialog","The Message displayed in the Dialog
is " & strText
Else
Reporter.ReportEvent micFail,"St
ep 21: Verifying the Message in the Dialog","The Message displayed in the Dialog
is NOT " & strText
Environment.Value("Execution_Log
") = "False"
End If
Browser("MasterFile").Dialog("Microsoft
Internet Explorer").WinButton("Cancel").Click
End If
End If
' Step 22
Call pageCheck_WebElementinTable("MasterFile","DR Documentation Deta
il","Deposit Agreement;Letter Agreement;Fees","")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 22: Verifying
if the Required Tabs are Displayed in the Page ' DR Documentation Detail'","The
Required Tabs are Displayed in the Page 'DR Documentation Detail"
Else
Reporter.ReportEvent micFail,"Step 22: Verifying
if the Required Tabs are Displayed in the Page ' DR Documentation Detail'","The
Required Tabs are NOT Displayed in the Page 'DR Documentation Detail"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Step 23
Call FillDRDocumentation("MasterFile","DR Documentation
Detail")
Call chkFlagImage("MasterFile","DR Documentation Detail"
,"DepositAgreement","Law Governing Deposit Agreement;Termination Period;Blocking
Type","Exist")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 23: Verifying
if the Flags are displayed Next to the Field Modified","The Flags are Displayed
next to the Modified Field"
Else
Reporter.ReportEvent micFail,"Step 23: Verifying
if the Flags are displayed Next to the Field Modified","The Flags are NOT Displ
ayed next to the Modified Field"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","DSFinDepositAgreement","No")
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","ChargeDSF","No")
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","NetDSFinCashDividend","No")
Call click_Image("MasterFile","DR Documentation Detail",
"Save")
Wait(5)
Call chkFlagImage("MasterFile","DR Documentation Detail"
,"DepositaryServiceFee","DSFinDepositAgreement;ChargeDSF;NetDSFinCashDividend","
Exist")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 23: Verifying
if the Flags are displayed Next to the Field Modified in Depositary Service Fie
ld","The Flags are Displayed next to the Modified Field Depositary Service Field
"
Else
Reporter.ReportEvent micFail,"Step 23: Verifying
if the Flags are displayed Next to the Field Modified Depositary Service Field"
,"The Flags are NOT Displayed next to the Modified Field Depositary Service Fiel
d"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Step 24 -- Select Fee Tab
Call click_WebElement("MasterFile","DR Documentation Detail","Fees")
Wait(2)
Call click_WebButton("MasterFile","DR Documentation Deta
il","Add")
Wait(2)
intInitialRowCounts = Browser("MasterFile").Page("DR Doc
umentation Detail").WebTable("Fees").RowCount
Browser("MasterFile").Page("DR Documentation Detail").We
bTable("Fees").ChildItem(intInitialRowCounts,1,"Image","0").Click
'Call click_Image("MasterFile","DR Documentation Detail"
,"FeeType")
Wait(2)
intRowCount = Browser("MasterFile").Page("DR Documentati
on Detail").Frame("lookupFrame").WebTable("FeeDescription").RowCount
For intRowCounter = 2 to intRowCount
intRowCounts = Browser("MasterFile").Page("DR Do
cumentation Detail").WebTable("Fees").RowCount
Browser("MasterFile").Page("DR Documentation Det
ail").WebTable("Fees").ChildItem(intRowCounts,1,"Image","0").Click
intRowCount = Browser("MasterFile").Page("DR Doc
umentation Detail").Frame("lookupFrame").WebTable("FeeDescription").RowCount
If intRowCount = 2 Then
strGetCellData = Browser("MasterFile").P
age("DR Documentation Detail").Frame("lookupFrame").WebTable("FeeDescription").G
etCellData(2,1)
Browser("MasterFile").Page("DR Documenta
tion Detail").WebElement("html tag:=TD","innertext:="& strGetCellData).Click
Exit For
Else
strGetCellData = Browser("MasterFile").P
age("DR Documentation Detail").Frame("lookupFrame").WebTable("FeeDescription").G
etCellData(2,1)
Browser("MasterFile").Page("DR Documenta
tion Detail").WebElement("html tag:=TD","innertext:="& strGetCellData).Click
Call click_WebButton("MasterFile","DR Do
cumentation Detail","Add")
End If
Next
intFeeRC = Browser("MasterFile").Page("DR Documentation
Detail").WebTable("Fees").RowCount
For intCount =3 to intFeeRC
strCellData = Browser("MasterFile").Page("DR Doc
umentation Detail").WebTable("Fees").ChildItem(intCount,2,"WebEdit","0").GetROPr
operty("value")
If strCellData = "" Then
Browser("MasterFile").Page("DR Documenta
tion Detail").WebTable("Fees").ChildItem(intCount,2,"WebEdit","0").Set "0"
End If
Next
Call click_Image("MasterFile","DR Documentation Detail",
"Save")
Call FlagImageCheckAllRow("MasterFile","DR Documentation
Detail","Fees","Fee Type","Exist")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 24: Verifying
if the New and the Approval Flag is Present next to the Field Modified","The Ne
w and Approval Flag is Present Next to the Field Modified"
Else
Reporter.ReportEvent micFail,"Step 24: Verifying
if the New and the Approval Flag is Present next to the Field Modified","The Ne
w OR Approval Flag is NOT Present Next to the Field Modified"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Step 25 : DSF in Deposit Agreement is "No"
'DSF in Deposit Agreement is "Yes"
Call click_WebElement("MasterFile","DR Documentation Det
ail","DepositAgreement")
Wait(5)
blnFlag1 = "True"
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","DSFinDepositAgreement","No")
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","ChargeDSF","No")
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","NetDSFinCashDividend","No")
Call click_Image("MasterFile","DR Documentation Detail",
"Save")
Wait(10)
If Browser( "MasterFile").Page("DR Documentation Detail"
).Image("ShowErrors").Exist(5) Then
blnFlag1 = "False"
End If
Wait(2)
If blnFlag1 = "True" Then
Reporter.ReportEvent micPass,"Step 25: Verfiying
the Functionality by changing the DSF in Deposit Agreement","The Functionality
is working as Required as No Validation Error Message is Displayed"
Else
Reporter.ReportEvent micFail, "Step 25: Verfiyin
g the Functionality by changing the DSF in Deposit Agreement","The Functionality
is NOT working as Required"
Environment.Value("Execution_Log") = "False"
End If
blnFlag2 = "False"
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","DSFinDepositAgreement","No")
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","ChargeDSF","No")
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","NetDSFinCashDividend","Yes")
Call click_Image("MasterFile","DR Documentation Detail",
"Save")
Wait(10)
If Browser("MasterFile").Page("DR Documentation Detail")
.Image("ShowErrors").Exist(5) Then
strMessageText = Browser("MasterFile").Page("D
R Documentation Detail").WebTable("ValidationError").GetROProperty("innertext")
If Instr(1,strMessageText, "If DSF in Deposit A
greement is No, Charge DSF and Net DSF from Cash Dividend must be No.") <> 0 The
n
blnFlag2 = "True"
End If
End If
Wait(2)
If blnFlag2 = "True" Then
Reporter.ReportEvent micPass,"Step 25: Verfiying
the Functionality by changing the DSF in Deposit Agreement","The Functionality
is working as Required as Validation Error Message is Displayed"
Else
Reporter.ReportEvent micFail, "Step 25: Verfiyin
g the Functionality by changing the DSF in Deposit Agreement","The Functionality
is NOT working as Required as No Validation Error Message is Displayed"
Environment.Value("Execution_Log") = "False"
End If
' Step 26
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","DSFinDepositAgreement","No")
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","ChargeDSF","No")
Call Select_Combo_Value("MasterFile","DR Documentation D
etail","NetDSFinCashDividend","No")
Call click_Image("MasterFile","DR Documentation Detail",
"Save")
Wait(5)
strDSF = get_WebList_Value("MasterFile","DR Documentation Detail","D
SFinDepositAgreement")
strChargeDSF = get_WebList_Value("MasterFile","DR Docume
ntation Detail","ChargeDSF")
strNetDSF = get_WebList_Value("MasterFile","DR Documenta
tion Detail","NetDSFinCashDividend")
If strDSF = "No" AND strChargeDSF = "No" AND strNetDSF
= "No" Then
Reporter.ReportEvent micPass,"Step 26: Verifying
if the Changes are Saved","The Changes are Saved"
Else
Reporter.ReportEvent micFail,"Step 26: Verifying
if the Changes are Saved","The Changes are NOT Saved"
Environment.Value("Execution_Log") = "False"
End If
' Step 27: Letter Agreement Tab
If Environment.Value("SponserUnsponser") = "S" Then
Call click_WebElement("MasterFile","DR Documenta
tion Detail","LetterAgreement")
Wait(2)
blnLetterFlag = "True"
If DataTable.Value("BifurcatedDR","DRLifeCycle")
= "Y" Then
strDRAppName = Browser("MasterFile").Pag
e("DR Documentation Detail").WebTable("DR").GetCellData(1,2)
If InStr(1, strDRAppName,"RegS") <> 0 Th
en
blnLetterFlag = "False"
End If
End If
If blnLetterFlag = "True" Then
InitialRowCount = Browser("MasterFile").
Page("DR Documentation Detail").WebTable("LetterAgreement").RowCount
Call click_WebButton("MasterFile","DR Do
cumentation Detail","Add_LetterAgreement")
Call click_Image("MasterFile","DR Docume
ntation Detail","LetterAgreementDate")
Call SetDate("MasterFile","DR Documentat
ion Detail",DataTable.Value("LetterAgreementDate","DRLifeCycle"))
Call Select_Combo_Value("MasterFile","DR
Documentation Detail","LetterAgreementExpiration",DataTable.Value("LetterAgreem
entExpiration","DRLifeCycle"))
Call Select_Combo_Value("MasterFile","DR
Documentation Detail","LetterReimbursementExpiration",DataTable.Value("LetterRe
imbursementExpiration","DRLifeCycle"))
Call click_Image("MasterFile","DR Docume
ntation Detail","Save")
Wait(2)
FinalRowCount = Browser("MasterFile").Pa
ge("DR Documentation Detail").WebTable("LetterAgreement").RowCount
If FinalRowCount > InitialRowCount Then
Reporter.ReportEvent micPass,"Ve
rifying if a New Row is added or Not","A New row is Added successfully in the Le
tter Agreement tab"
Else
Reporter.ReportEvent micFail,"Ve
rifying if a New Row is added or Not","A New Row is added successfully in the Le
tter Agreement tab"
Environment.Value("Execution_Log
") = "False"
End If
' Checking for the New and Approval Flag
in the Newly added Row
Call FlagImageCheck("MasterFile","DR Doc
umentation Detail","LetterAgreement","Exist")
If Environment.Value("TestCase_Log") = "
True" And FinalRowCount > InitialRowCount Then
Reporter.ReportEvent micPass,"St
ep 27: Check for the Flag Existance in Letter Agreement tab","The New, Approval
Image is Displayed in the Newly added row in Letter Agreement tab"
Else
Reporter.ReportEvent micFail,"St
ep 27: Check for the Flag Existance in Letter Agreement tab","The New , Approva
l Flag is Not displayed in the Newly added row in the Letter Agreement tab"
Environment.Value("TestCase_Log"
) = "True"
Environment.Value("Execution_Log
") = "False"
End If
End If
End If
' Step 28 - Clicking on the DR
Wait(5)
strDRAppName = Browser("MasterFile").Page("DR Documentation Detail")
.WebTable("DR").GetCellData(1,2)
Browser("MasterFile").Page("DR Documentation Detail").We
bElement("html tag:=TD","innertext:=" & strDRAppName,"class:=tabSelected","index
:=0").Click
If Browser("MasterFile").Dialog("Microsoft Internet Expl
orer").Exist(5) Then
strMessageText = Browser("MasterFile").Dialog("M
icrosoft Internet Explorer").Static("MessageText").GetROProperty("text")
strReqtext = "Please click OK to Save Changes (i
f any) or click Cancel to Continue"
If Trim(strMessageText) = Trim(strReqText) Then
Reporter.ReportEvent micPass,"Step 28: V
erifying the Message in the Dialog","The text displayed in the Dialog is " & str
MessageText
Else
Reporter.ReportEvent micFail,"Step 28: V
erifying the Message in the Dialog","The text displayed in the Dialog is NOT " &
strMessageText
Environment.Value("Execution_Log") = "Fa
lse"
End If
Browser("MasterFile").Dialog("Microsoft Internet
Explorer").WinButton("Cancel").Click
End If
Wait(5)
If Browser("MasterFile").Page("DR Documentation Detail")
.Exist(5) Then
strDRAppName = Browser("MasterFile").Page("DR Do
cumentation Detail").WebTable("DR").GetCellData(1,2)
Browser("MasterFile").Page("DR Documentation Det
ail").WebElement("html tag:=TD","innertext:=" & strDRAppName,"class:=tabSelected
","index:=0").Click
If Browser("MasterFile").Dialog("Microsoft Inter
net Explorer").Exist(5) Then
strMessageText = Browser("MasterFile").D
ialog("Microsoft Internet Explorer").Static("MessageText").GetROProperty("text")
strReqtext = "Please click OK to Save Ch
anges (if any) or click Cancel to Continue"
If Trim(strMessageText) = Trim(strReqTex
t) Then
Reporter.ReportEvent micPass,"St
ep 28: Verifying the Message in the Dialog","The text displayed in the Dialog is
" & strMessageText
Else
Reporter.ReportEvent micFail,"St
ep 28: Verifying the Message in the Dialog","The text displayed in the Dialog is
NOT " & strMessageText
Environment.Value("Execution_Log
") = "False"
End If
Browser("MasterFile").Dialog("Microsoft
Internet Explorer").WinButton("Cancel").Click
End If
End If
If Browser("MasterFile").Page("DR Profile").Exist(5) The
n
Reporter.ReportEvent micPass,"Step 29: Verifiyin
g if the DR Profile page is Dispalyed","The DR Profiel page is Dispalyed"
Else
Reporter.ReportEvent micFail,"Step 29: Verifiyin
g if the DR Profile page is Dispalyed","The DR Profiel page is NOTDispalyed"
Environment.Value("Execution_Log") = "False"
End If
' Step 30
' Call click_Image("MasterFile","DR Profile","Details_Effe
ctiveDate")
' Call SetDate("MasterFile","DR Profile",DataTable.Value("
Details_EffectiveDate","DRLifeCycle"))
' If Browser("MasterFile").Dialog("Microsoft Internet Expl
orer").Exist(2) Then
' Browser("MasterFile").Dialog("Microsoft Internet
Explorer").WinButton("OK").Click
' End If
Call Select_Combo_Value("MasterFile","DR Profile","Detai
ls_Status",DataTable.Value("Details_Status","DRLifeCycle"))
Call click_Image("MasterFile","DR Profile","Save")
If Browser("MasterFile").Page("DR Profile").Image("ShowE
rrors").Exist(5) Then
strInnerText = Browser("MasterFile").Page("DR Profile").WebTable
("ErrorMessage").GetROProperty("innertext")
strRequiredText = "Issuer Documentation must hav
e MAL Flag set"
If Instr(1,strInnerText,strRequiredtext) <> 0 Th
en
Reporter.ReportEvent micPass,"Step 30: V
erifying if a Error Message is Displayed","An Error Message is Dispalyed with th
e Error " & strRequiredText
Else
Reporter.ReportEvent micFail,"Step 30: V
erifying if a Error Message is Displayed","An Error Message is NOT Dispalyed wit
h the Error " & strRequiredText
Environment.Value("Execution_Log") = "Fa
lse"
End If
End If
End Function
'===============================================================================
====================================================
Public Function DRIssuerDocumentation()
'Call click_WebElement("MasterFile","DR Profile","IssuerName")
Wait(2)
strIssuerName = Browser("MasterFile").Page("DR Profile").WebTabl
e("Issuer").GetCellData(1,2)
Browser("MasterFile").Page("DR Profile").WebElement("html tag:=T
D","innertext:="& strIssuerName,"index:=0").Click
If Browser("MasterFile").Dialog("Microsoft Internet Explorer").E
xist(5) Then
strMessageText = Browser("MasterFile").Dialog("Microsoft
Internet Explorer").Static("MessageText").GetROProperty("text")
strReqtext = "Please click OK to Save Changes (if any) o
r click Cancel to Continue"
If Trim(strMessageText) = Trim(strReqText) Then
Reporter.ReportEvent micPass,"Step 31: Verifying
the Message in the Dialog","The text displayed in the Dialog is " & strMessageT
ext
Else
Reporter.ReportEvent micFail,"Step 31: Verifying
the Message in the Dialog","The text displayed in the Dialog is NOT " & strMess
ageText
Environment.Value("Execution_Log") = "False"
End If
Browser("MasterFile").Dialog("Microsoft Internet Explore
r").WinButton("Cancel").Click
End If
If Browser("MasterFile").Page("Issuer Profile").Exist(5) Then
Reporter.ReportEvent micPass,"Step 32: Verifying if the
Page ' Issuer Profile ' is Displayed or Not","The Page 'Issuer Profile' is Displ
ayed"
Else
Reporter.ReportEvent micFail,"Step 32: Verifying if the
Page ' Issuer Profile ' is Displayed or Not","The Page 'Issuer Profile' is NOT D
isplayed"
Environment.Value("Execution_Log") = "False"
End If
' Step 33 -- Clicking on Issuer Documentation
Wait(2)
Call click_WebElement("MasterFile","Issuer Profile","IssuerDocum
entation")
If Browser("MasterFile").Dialog("Microsoft Internet Explorer").E
xist(5) Then
Browser("MasterFile").Dialog("Microsoft Internet Explore
r").WinButton("Cancel").Click
End If
If Browser("MasterFile").Page("Issuer Documentation").Exist(5) T
hen
If Browser("MasterFile").Page("Issuer Documentation").We
bElement("BCP_PAF").Exist(2) OR Browser("MasterFile").Page("Issuer Documentatio
n").WebElement("SECFilingandMALFOL").Exist(2) Then
Reporter.ReportEvent micPass,"Step 33: Verifying
the Required Tabs are Present or NOT","The Required Tab 'BCP_PAF' Or 'SECFiling
andMALFOL' or Both is Present "
Else
Reporter.ReportEvent micFail,"Step 33: Verifying
the Required Tabs are Present or NOT","The Required Tab 'BCP_PAF' Or 'SECFiling
andMALFOL' is NOT Present"
Environment.Value("Execution_Log") = "False"
End If
End If
' Step 34 - Selecting SECFilingandMALFOL Tab
Call click_WebElement("MasterFile","Issuer Documentation","SECFilingandM
ALFOL")
Call pageCheck_WebListOR("MasterFile","Issuer Documentation","12
gFiler;20FFiler;OnWebSite")
Call pageCheck_WebEditOR("MasterFile","Issuer Documentation","CC
CCode;MAL_FOL;NonUSGovernment")
If Environment.Value("TestCase_Log") = "True" Then
Reporter.ReportEvent micPass,"Step 34: Verifying if the
Required Fields are Present in the Tab 'SECFilingandMALFOL'","The Required Field
s are Present in the Tab 'SECFilingandMALFOL'"
Else
Reporter.ReportEvent micFail,"Step 34: Verifying if the
Required Fields are Present in the Tab 'SECFilingandMALFOL'","The Required Field
s are NOT Present in the Tab 'SECFilingandMALFOL'"
Environment.Value("TestCase_Log") = "True"
Environment.Value("Execution_Log") = "False"
End If
' Step 35
intVal = Browser("MasterFile").Page("Issuer Documentation").WebE
dit("MAL_FOL").GetROProperty("readonly")
If intVal <> 1 Then
Call set_WebEdit_Value("MasterFile","Issuer Documentatio
n","MAL_FOL",DataTable("Issuer_MAL","DRLifeCycle"))
strValue = get_WebEdit_Value("MasterFile","Issuer Docume
ntation","MAL_FOL")
If strValue = DataTable.Value("Issuer_MAL","DRLifeCycle"
) Then
Reporter.ReportEvent micPass,"Step 35: Verifying
if the Entered Value is Displayed or NOT","The Entered Value is " & DataTable.V
alue("Issuer_MAL","DRLifeCycle")
Else
Reporter.ReportEvent micFail,"Step 35: Verifying
if the Entered Value is Displayed or NOT","The Entered Value is NOT " & DataTab
le.Value("Issuer_MAL","DRLifeCycle")
Environment.Value("Execution_Log") = "False"
End If
Else
Call Select_Combo_Value("MasterFile","Issuer Documentati
on","OnWebsite",DataTable("Issuer_OnWebsite","DRLifeCycle"))
strValue = get_WebList_Value("MasterFile","Issuer Docum
entation","OnWebsite")
If strValue = DataTable.Value("Issuer_OnWebsite","DRLife
Cycle") Then
Reporter.ReportEvent micPass,"Step 35: Verifying
if the Selected Value is Displayed or NOT","The Selected Value is " & DataTable
.Value("Issuer_OnWebsite","DRLifeCycle")
Else
Reporter.ReportEvent micFail,"Step 35: Verifying
if the Selected Value is Displayed or NOT","The Selected Value is NOT " & DataT
able.Value("Issuer_OnWebsite","DRLifeCycle")
Environment.Value("Execution_Log") = "False"
End If
End If
' Step 36 : Fill SECFilingandMALFOL Tab
Call set_WebEdit_Value("MasterFile","Issuer Documentation","NonU
SGovernment",DataTable.Value("NonUSGovernment","DRLifeCycle"))
Call set_WebEdit_Value("MasterFile","Issuer Documentation","CCCC
ode",DataTable.Value("CCCCode","DRLifeCycle"))
Call set_WebEdit_Value("MasterFile","Issuer Documentation","CIKC
ode",DataTable.Value("CIKCode","DRLifeCycle"))
Call Select_Combo_Value("MasterFile","Issuer Documentation","20F
Filer",DataTable.Value("Issuer_20FFiler","DRLifeCycle"))
Call Select_Combo_Value("MasterFile","Issuer Documentation","12g
Filer",DataTable.Value("Issuer_12g3Filer","DRLifeCycle"))
blnFlag = "False"
blnExistFlag = Browser("MasterFile").Page("Issuer Documentation"
).WebElement("BCP_PAF").Exist(5)
If blnExistFlag = "False" Then
Call click_Image("MasterFile","Issuer Documentation","Sa
ve")
Else
blnFlag = "True"
End If
If blnFlag = "True" Then
Call click_WebElement("MasterFile","Issuer Documentation
","BCP_PAF")
Wait 2
Call Select_Combo_Value("MasterFile","Issuer Documentati
on","BCPPAF_Approval",DataTable.Value("BCPPAF_Approval","DRLifeCycle"))
Call Select_Combo_Value("MasterFile","Issuer Documentati
on","BCPPAF_Required",DataTable.Value("BCPPAF_Required","DRLifeCycle"))
Call click_Image("MasterFile","Issuer Documentation","Ap
provalDate")
Call SetDate("MasterFile","Issuer Documentation",DataTab
le.Value("BCPPAF_ApprovalDate","DRLifeCycle"))
Call click_Image("MasterFile","Issuer Documentation","Di
visionApproved")
intRowCount = Browser("MasterFile").Page("Issuer Documen
tation").Frame("lookupFrame").WebTable("Division Name").RowCount
For intRowCounter = 1 to intRowCount
strCellData = Browser("MasterFile").Page("Issuer
Documentation").Frame("lookupFrame").WebTable("Division Name").GetCellData(intR
owCounter,1)
If strCellData = DataTable.Value("BCPPAF_Divisio
nApproved","DRLifeCycle") Then
Browser("MasterFile").Page("Issuer Docum
entation").WebElement("html tag:=TD","innertext:="& strCellData).Click
Exit For
End If
Next
Call click_Image("MasterFile","Issuer Documentation","Sa
ve")
strApproval = get_WebList_Value("MasterFile","Issuer Doc
umentation","BCPPAF_Approval")
strRequired = get_WebList_Value("MasterFile","Issuer Doc
umentation","BCPPAF_Required")
strApprovalDate = get_WebEdit_Value("MasterFile","Issuer
Documentation","BCPPAF_ApprovalDate")
strDivisionApproved = get_WebEdit_Value("MasterFile","Is
suer Documentation","BCPPAF_DivisionApproved")
strDataTableDate = Replace(DataTable.Value("BCPPAF_Appro
valDate","DRLifeCycle"),";","-")
If strApproval = DataTable.Value("BCPPAF_Approval","DRLi
feCycle") AND strRequired = DataTable.Value("BCPPAF_Required","DRLifeCycle") AND
DateValue(strApprovalDate) = DateValue(strDataTableDate) AND strDivisionApprove
d = DataTable.Value("BCPPAF_DivisionApproved","DRLifeCycle") Then
Reporter.ReportEvent micPass,"Step 36, 37: Verfi
ying if the Values are Saved or NOT in the Issuer Documentation","The Values are
Saved in the Issuer Documentation"
Else
Reporter.ReportEvent micFail,"Step 36, 37: Verfi
ying if the Values are Saved or NOT in the Issuer Documentation","The Values are
NOT Saved in the Issuer Documentation"
Environment.Value("Execution_Log") = "False"
End If
End If
' Step 38
'Call click_WebElement("MasterFile","Issuer Documentation","Issu
erName")
strAppIssuerName = Browser("MasterFile").Page("Issuer Documentat
ion").WebTable("Issuer").GetCellData(1,2)
Browser("MasterFile").Page("Issuer Documentation").WebElement("html tag:
=TD","innertext:=" & strAppIssuerName,"class:=tabSelected").Click
If Browser("MasterFile").Dialog("Microsoft Internet Explorer").Exist(5)
Then
strMessageText = Browser("MasterFile").Dialog("Microsoft
Internet Explorer").Static("MessageText").GetROProperty("text")
strReqtext = "Please click OK to Save Changes (if any) o
r click Cancel to Continue"
If Trim(strMessageText) = Trim(strReqText) Then
Reporter.ReportEvent micPass,"Step 38: Verifying
the Message in the Dialog","The text displayed in the Dialog is " & strMessageT
ext
Else
Reporter.ReportEvent micFail,"Step 38: Verifying
the Message in the Dialog","The text displayed in the Dialog is NOT " & strMess
ageText
Environment.Value("Execution_Log") = "False"
End If
Browser("MasterFile").Dialog("Microsoft Internet Explore
r").WinButton("Cancel").Click
If Browser("MasterFile").Dialog("Microsoft Internet Expl
orer").Exist(5) Then
Browser("MasterFile").Dialog("Microsoft Internet
Explorer").WinButton("Cancel").Click
End If
Else
Reporter.ReportEvent micFail,"Step 38: Verifying if the
Dialog is Dispalyed or NOT","The Dialog is NOT Dispalyed"
End If
End Function
'++++++++++++++++++++== Add the Belo code in Line 5305
'===============================================================================
=====================
Public Function SelectDRExchange(strBrowserName,strPageName,strTableName,strRequ
iredValue)
blnFlag = "False"
While blnFlag = "False"
intRowCount = Browser(strBrowserName).Page(strP
ageName).Frame("lookupFrame").WebTable(strTableName).RowCount
For intRowCounter = 1 to intRowCount
intColumnCount = Browser(strBrow
serName).Page(strPageName).Frame("lookupFrame").WebTable(strTableName).ColumnCou
nt(intRowCounter)
For intColumnCounter = 1 to intC
olumnCount
strCellData = Br
owser(strBrowserName).Page(strPageName).Frame("lookupFrame").WebTable(strTableNa
me).GetCellData(intRowCounter,intColumnCounter)
'If Trim(strCell
Data) = DataTable.Value("DRExchange","DRLifeCycle") Then
If Trim(strCellD
ata) = Trim(strRequiredValue) then
Browser(
strBrowserName).Page(strPageName).WebElement("html tag:=TD","innertext:= " & str
CellData).Click
blnFlag
= "True"
Exit For
End If
Next
If blnFlag = "True" Then
Exit For
End If
Next
If blnFlag = "False" Then
Browser(strBrowserName).Page(str
PageName).Frame("lookupFrame").Image("file name:=nextbutton.gif").Click
End If
Wend
Wait(2)
End Function
'===============================================================================
===================================================
' Name of the Function : chkFlagImage
' Scope of the Function : Public
' Author : Shyam H D
' Description : This function checks for the Flag Image that will be dispa
lyed next to the Modified fields.
' Parameters accepted : BrowserName, PageName and Name of the Fields that ar
e modified.
' Parameter returned : Null
' Date and / or Version : 20-10-2008,version 1.0
' Call Statement : 'Call chkFlagImage("MasterFile","Profile - HOLDR
Profile","Detail","US Exchange;Price","Exist")
'===============================================================================
===================================================
Public Function chkFlagImage(strBrowserName, strPageName, strTableName, strAllCh
eckVariable, strCheckFlag)
blnImageFlag = "False"
strCheckVariable = Split(strAllCheckVariable, ";", -1, 1)
For intVariable = 0 To UBound(strCheckVariable)
intRowCount = Browser(strBrowserName).Page(strPageName).WebTable(strTabl
eName).RowCount
For intRowCounter = 1 To intRowCount
intColumnCount = Browser(strBrowserName).Page(strPageName).WebTable(
strTableName).ColumnCount(intRowCounter)
For intColumnCounter = 1 To intColumnCount
strGetCellData = Trim(Browser(strBrowserName).Page(strPageName).
WebTable(strTableName).GetCellData(intRowCounter, intColumnCounter))
If strGetCellData = strCheckVariable(intVariable) Then
intImageCount = Browser(strBrowserName).Page(strPageName).We
bTable(strTableName).ChildItemCount(intRowCounter, intColumnCounter + 1, "Image"
)
If intImageCount > 0 Then
For intImageCounter = 0 To intImageCount - 1
strName = Browser(strBrowserName).Page(strPageName).
WebTable(strTableName).ChildItem(intRowCounter, intColumnCounter + 1, "Image", i
ntImageCounter).GetROProperty("alt")
If strName = " Approval Status:Pending Approval" Or
strName = "Approval Status:Pending Approval" Or strName = "Corporate Action Appr
oval Status:Pending Approval" Then
blnImageFlag = "
True"
Exit For
End If
Next
Select Case strCheckFlag
Case "Exist"
If blnImageFlag = "True"Then
Reporter.ReportEvent micPass, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is Present next to the Field " & strCheckVariab
le(intVariable)
Else
Reporter.ReportEvent micFail, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is NOT Present next to the Field" & strCheckVar
iable(intVariable)
'captureScreenshot
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "False"
End If
Case "Not Exist"
If blnImageFlag = "False" Then
Reporter.ReportEvent micPass, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is NOT Present next to the Field " & strCheckVa
riable(intVariable)
Else
Reporter.ReportEvent micFail, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is Present next to the Field " & strCheckVariab
le(intVariable)
'captureScreenshot
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "False"
End If
End Select
ElseIf intImageCount = 0 Then
Select Case strC
heckFlag
Case "Exist"
If blnImageFlag = "True"Then
Reporter.ReportEvent micPass, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is Present next to the Field " & strCheckVariab
le(intVariable)
Else
Reporter.ReportEvent micFail, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is NOT Present next to the Field" & strCheckVar
iable(intVariable)
'captureScreenshot
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "False"
End If
Case "Not Exist"
If blnImageFlag = "False" Then
Reporter.ReportEvent micPass, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is NOT Present next to the Field " & strCheckVa
riable(intVariable)
Else
Reporter.ReportEvent micFail, "Verifying for the Approval Image after changing t
he Details", "The Approval Image is Present next to the Field " & strCheckVariab
le(intVariable)
'captureScreenshot
Environment.Value("Execution_Log") = "False"
Environment.Value("TestCase_Log") = "False"
End If
End Select
End If
Exit For
End If
Next
Next
Next
End Function
'===============================================================================
==================================
'===============================================================================
============================
' Name of the Function : chkResultinTable
' Scope of the Function : Public
' Author : Shyam H D
' Description : This function is to Used to verfiy if the R
esults are displayed in the Table as per the Search Criteria
' Parameters accepted : BrowserName, PageName,Table Name, the Field
name and the Search Name
' Parameter returned : Null
' Date and / or Version : 26-11-2008,version 1.0
'===============================================================================
============================
'===============================================================================
=======================================================
'===============================================================================
=================================
'===============================================================================
==========================