public void Verify_Fundtransfer_IMS_All_History() { #region declaration IMS_Base imsAdmin = new IMS_Base(); IMS_AdminSuite.Common commIMS = new IMS_AdminSuite.Common(); Ladbrokes_IMS_TestRepository.Common commTest = new Ladbrokes_IMS_TestRepository.Common(); Registration_Data regData = new Registration_Data(); AdminSuite.Common adminComm = new AdminSuite.Common(); #endregion AddTestCase("Verifying fund transfer through IMS admin", "Fund should be transferred successfully"); try { imsAdmin.Init(); commIMS.SearchCustomer_Newlook(imsAdmin.IMSDriver, ReadxmlData("depdata", "user", DataFilePath.Accounts_Wallets)); List <string> wallet = ReadxmlData("depdata", "TransWalletDropDown", DataFilePath.Accounts_Wallets).ToString().Split(';').ToList <string>(); commIMS.FundTransfer_History(imsAdmin.IMSDriver, ReadxmlData("depdata", "AuditFromWallet", DataFilePath.Accounts_Wallets), ReadxmlData("depdata", "AuditToWallet", DataFilePath.Accounts_Wallets), ReadxmlData("depdata", "AuditAmt", DataFilePath.Accounts_Wallets)); } catch (Exception e) { exceptionStack(e); // CaptureScreenshot(MyBrowser, "Portal"); CaptureScreenshot(imsAdmin.IMSDriver, "IMS"); Fail("Affiliate Customer Registration/Validation has failed"); Pass(); } finally { imsAdmin.Quit(); } }
public void Verify_Title_Russian() { #region Declaration IMS_Base baseIMS = new IMS_Base(); IMS_AdminSuite.Common commIMS = new IMS_AdminSuite.Common(); Registration_Data regData = new Registration_Data(); Ladbrokes_IMS_TestRepository.Common commTest = new Ladbrokes_IMS_TestRepository.Common(); Login_Data loginData = new Login_Data(); MyAcct_Data acctData = new MyAcct_Data(); #endregion #region DriverInitiation IWebDriver driverObj; ISelenium iBrowser = commonFramework.GetDriverByTestCaseName(SeleniumContainer, Gallio.Framework.TestContext.CurrentContext.Test.Name); driverObj = browserInitialize(iBrowser); #endregion Ladbrokes_IMS_TestRepository.Common Testcomm = new Ladbrokes_IMS_TestRepository.Common(); string temp = Registration_Data.title; try { Registration_Data.title = "Г - н"; AddTestCase("Russian Language", "Registration should be successfull"); regData.update_Registration_Data(ReadxmlData("regdata", "Fname", DataFilePath.Accounts_Wallets), ReadxmlData("regdata", "country_germany_german", DataFilePath.Accounts_Wallets), ReadxmlData("regdata", "City_Web", DataFilePath.Accounts_Wallets), ReadxmlData("regdata", "Password", DataFilePath.Accounts_Wallets)); //Change the language wAction._ClickAndMove(driverObj, ORFile.Ladbrokes_Header, wActions.locatorType.xpath, "LanguageMenu", FrameGlobals.elementTimeOut, "Header element Change language menu not found"); wAction._Click(driverObj, ORFile.Ladbrokes_Header, wActions.locatorType.xpath, "Language_Russian", "Language Russian in menu not found", 0, false); //register in Russian wAction._Click(driverObj, ICE.ObjectRepository.ORFile.Accounts_Wallets_Registration, wActions.locatorType.xpath, "Join_Russian_Btn", "Join button not found", 0, false); AnW.Registration_PlaytechPages(driverObj, ref regData); // Testcomm.Createcustomer_PostMethod(ref regData, Registration_Data.title); Pass("Customer registered succesfully"); baseIMS.Init(); commIMS.SearchCustomer_Newlook(baseIMS.IMSDriver, regData.username); baseIMS.IMSDriver.SwitchTo().DefaultContent(); BaseTest.Assert.IsTrue(baseIMS.IMSDriver.FindElement(By.Id("title")).GetAttribute("value") == Registration_Data.title, "title did not match in IMS Admin. Expected:" + Registration_Data.title + " Actual:" + baseIMS.IMSDriver.FindElement(By.Id("title")).GetAttribute("value")); } catch (Exception e) { exceptionStack(e); CaptureScreenshot(driverObj, "Portal"); CaptureScreenshot(baseIMS.IMSDriver, "IMS"); Fail("Verify title : scenario failed"); } finally { Registration_Data.title = temp; } }
public void Verify_SelfExcl_ValidateOB() { #region Declaration Registration_Data regData = new Registration_Data(); IMS_Base baseIMS = new IMS_Base(); #endregion try { AddTestCase("Verify setting selfexclusion for a debit customer in OB", "Credit limit should be set successfully"); regData.update_Registration_Data(ReadxmlData("regdata", "Fname", DataFilePath.IP2_Authetication), ReadxmlData("regdata", "country_UK", DataFilePath.IP2_Authetication), ReadxmlData("regdata", "City_Web", DataFilePath.IP2_Authetication), ReadxmlData("regdata", "Password", DataFilePath.IP2_Authetication)); baseIMS.Init(); #region NewCustTestData regData.email = "*****@*****.**"; commTest.Createcustomer_PostMethod(ref regData); #endregion commIMS.SearchCustomer_Newlook(baseIMS.IMSDriver, regData.username, false); commIMS.SelfExclude_Customer(baseIMS.IMSDriver, regData.username); WriteCommentToMailer("UserName: "******";\nPassword: "******"Customer created: " + regData.username, ""); Pass(); baseIMS.Quit(); adminBase.Init(); Thread.Sleep(TimeSpan.FromMinutes(1)); adminComm.SearchCustomer(regData.username, adminBase.MyBrowser); BaseTest.Assert.IsTrue(wAction.IsElementPresent(adminBase.MyBrowser, By.XPath("//b[text()='PT_SELFEX']")), "Self exclusion is not synced with OB"); adminBase.Quit(); WriteUserName(regData.username); Pass(); } catch (Exception e) { exceptionStack(e); CaptureScreenshot(baseIMS.IMSDriver, "IMS"); CaptureScreenshot(adminBase.MyBrowser, "OB"); Fail("Verify_SelfExcl_DebitCustomer_Ip2_BVT- failed"); } finally { baseIMS.Quit(); adminBase.Cleanup(); } }
public void Verify_Games_Login_Logout_1908() { #region DriverInitiation IWebDriver driverObj; ISelenium iBrowser = commonFramework.GetDriverByTestCaseName(SeleniumContainer, Gallio.Framework.TestContext.CurrentContext.Test.Name); driverObj = browserInitialize(iBrowser, FrameGlobals.GamesURL); #endregion #region Declaration Registration_Data regData = new Registration_Data(); // Configuration testdata = TestDataInit(); IMS_Base baseIMS = new IMS_Base(); IMS_AdminSuite.Common commIMS = new IMS_AdminSuite.Common(); Ladbrokes_IMS_TestRepository.Common commTest = new Ladbrokes_IMS_TestRepository.Common(); Login_Data loginData = new Login_Data(); MyAcct_Data acctData = new MyAcct_Data(); #endregion AddTestCase("Verify login is successfull in games", "Login should be successfully"); try { #region NewCustTestData regData.email = "*****@*****.**"; commTest.Createcustomer_PostMethod(ref regData); loginData.username = regData.username; loginData.password = regData.password; #endregion WriteCommentToMailer("UserName: "******";\nPassword: "******"log", "ClientPlatform_games", DataFilePath.IP2_Authetication)); commIMS.Validate_SessionLogin(baseIMS.IMSDriver, IMS_Control_PlayerDetails.LoginTime_XP, DateTime.Now.ToString("yyyy-MM-dd")); commIMS.Open_CheckLog(baseIMS.IMSDriver); commIMS.Validate_CheckLog(baseIMS.IMSDriver, IMS_Control_CasinoLog.SessionLogin_XP, ReadxmlData("log", "ClientPlatform_games", DataFilePath.IP2_Authetication)); commIMS.Validate_CheckLog(baseIMS.IMSDriver, IMS_Control_CasinoLog.SessionLogin_XP, Generic.GetPublic_IPAddress()); ip2.Logout_Games(driverObj); commIMS.SearchCustomer_Newlook(baseIMS.IMSDriver, loginData.username, false); commIMS.Validate_SessionLogin(baseIMS.IMSDriver, IMS_Control_PlayerDetails.ClientPlatform_XP, ReadxmlData("log", "ClientPlatform_games", DataFilePath.IP2_Authetication)); commIMS.Validate_SessionLogin(baseIMS.IMSDriver, IMS_Control_PlayerDetails.LoginTime_XP, DateTime.Now.ToString("yyyy-MM-dd")); commIMS.Validate_SessionLogin(baseIMS.IMSDriver, IMS_Control_PlayerDetails.LogoutTime_XP, DateTime.Now.ToString("yyyy-MM-dd")); commIMS.Open_CheckLog(baseIMS.IMSDriver); commIMS.Validate_CheckLog(baseIMS.IMSDriver, IMS_Control_CasinoLog.SessionLogout_XP, ReadxmlData("log", "ClientPlatform_games", DataFilePath.IP2_Authetication)); commIMS.Validate_CheckLog(baseIMS.IMSDriver, IMS_Control_CasinoLog.SessionLogout_XP, Generic.GetPublic_IPAddress()); Pass("games login successfully"); } catch (Exception e) { exceptionStack(e); CaptureScreenshot(driverObj, "portal"); CaptureScreenshot(baseIMS.IMSDriver, "IMS"); Fail("Verify_Games_Login_Logout - failed"); } finally { baseIMS.Quit(); } }