Exemplo n.º 1
0
        public void contactUs()
        {
            //Initializing the objects
            LoginHelper loginHelper = new LoginHelper(GetWebDriver());
            ContactUsHelper contactUsHelper = new ContactUsHelper(GetWebDriver());

            //Verify Page title
            VerifyTitle("Login");

            //Click on Contact Us
            contactUsHelper.ClickElement("ContactUsLink");

            //Enter Name
            contactUsHelper.TypeText("EnterName","Test");

            //Enter Email
            contactUsHelper.TypeText("EnterEmail", "*****@*****.**");

            //Enter Subject
            contactUsHelper.TypeText("EnterSubject", "Test Subject");

            //Enter Message
            contactUsHelper.TypeText("EnterMessage", "This is Test Message");

            //Click on Send
            contactUsHelper.ClickElement("Send");
            contactUsHelper.WaitForWorkAround(3000);

            //Capture screenshot fot the screen
            //            TakeScreenshot("ContactUs");
        }
Exemplo n.º 2
0
        public void createProcessor()
        {
            //   string[] username = null;
            //     string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            //   username = oXMLData.getData("settings/Credentials", "username");
            //    password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var createProcessorHelper = new CreateProcessorHelper(GetWebDriver());

            //Variable
            var name = "Test" + GetRandomNumber();
            var Test = "New" + GetRandomNumber();

            //Login with valid credential  Username
            createProcessorHelper.TypeText("EnterUsername", "selcorp");

            //Login with valid credential password
            createProcessorHelper.TypeText("EnterPassword", "seWelcome2");

            //Click On Login Button
            createProcessorHelper.ClickElement("ClickOnLoginButtojn");

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click on Residual Income tab
            createProcessorHelper.ClickElement("ClickMasterTab");

            //Click to Import
            createProcessorHelper.redirectToPage();

            //Click On Create
            createProcessorHelper.ClickElement("ClickOnCreate");

            //Click On Save Btn
            createProcessorHelper.ClickElement("ClickOnSaveBtn");
            createProcessorHelper.WaitForWorkAround(3000);

            //Enter Processor name
            createProcessorHelper.TypeText("ProcessorName", name);

            //Enter ProcessorCode
            createProcessorHelper.TypeText("ProcessorCode", Test);

            //Click On Save Btn
            createProcessorHelper.ClickElement("ClickOnSaveBtn");
            createProcessorHelper.WaitForWorkAround(3000);

            //Verify text present
            createProcessorHelper.VerifyPageText("The processor is successfully created!!");
            createProcessorHelper.WaitForWorkAround(3000);
        }
Exemplo n.º 3
0
        //[TestMethod]
        public void sendEmailAdmin()
        {
            string[] username = null;
            string[] password = null;

            XMLParse oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            LoginHelper loginHelper = new LoginHelper(GetWebDriver());
            ClientsHelper clientHelper = new ClientsHelper(GetWebDriver());
            SendEmailAdminHelper sendEmailAdminHelper = new SendEmailAdminHelper(GetWebDriver());

            // Variable
            String name = "Testing Subject" + RandomNumber(1,99);
            String email = "Test" + RandomNumber(1,999)+ "@gmail.com.com";

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click On  Admin
            sendEmailAdminHelper.RedirectToAdmin();

            //################################# SEND E-MAIL #############################################

            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/mails");

            VerifyTitle("Mails");

            // Click On send Email
            sendEmailAdminHelper.ClickElement("ClickOnSendEmail");

            //Verify title
            VerifyTitle("Compose");

            //Enter to
            sendEmailAdminHelper.TypeText("To", "*****@*****.**");
            //Enter Name
            sendEmailAdminHelper.TypeText("EnterSubjuct", name);

            //Click on importance
            sendEmailAdminHelper.ClickElement("importance");

            //Select Department
            sendEmailAdminHelper.TypeText("EnterMsgtxt", "This is testing description notes");

            //cLICK on Save
            sendEmailAdminHelper.ClickElement("ClickOnSend");

            //Wait for text
            sendEmailAdminHelper.WaitForText("E-Mail Sent Successfully.", 30);
        }
        public void profilePicUplaodField()
        {
            string[] username = null;
             string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

              username = oXMLData.getData("settings/Credentials", "username");
               password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Go to Edit profile page
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/editProfile");

            //Verify title
            VerifyTitle("Edit Profile");

            //Verify upload file field availabe
            Assert.IsTrue(loginHelper.IsElementVisible("//*[@id='EmployeeProfileImage']"));
        }
Exemplo n.º 5
0
        public void merchantTabCorp()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username2");
            password = oXMLData.getData("settings/Credentials", "password2");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var clientHelperNewSkin = new ClientHelperNewSkin(GetWebDriver());

            //VARIABLE
            var name = "TestEmployee" + GetRandomNumber();

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click on Agent in Topmenu
            clientHelperNewSkin.ClickElement("ClickOnMerchnatTab");

            //verify
            clientHelperNewSkin.VerifyPageText("Merchants");
            clientHelperNewSkin.WaitForWorkAround(3000);
        }
        public void createAndDeletePDFCategories()
        {
            string[] username = null;
               string[] password = null;

            XMLParse oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username2");
            password = oXMLData.getData("settings/Credentials", "password2");

            //Initializing the objects
            LoginHelper loginHelper = new LoginHelper(GetWebDriver());
            ClientsHelper clientHelper = new ClientsHelper(GetWebDriver());
            LoginAsCorpHelper loginAsCorpHelper = new LoginAsCorpHelper(GetWebDriver());
            CreatePDFCategoriesHelper createPDFCategoriesHelper = new CreatePDFCategoriesHelper(GetWebDriver());

            //Variable random

            String  name = "Test" + RandomNumber(1, 99);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Redirect To
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/pdf_templates/categories");
            createPDFCategoriesHelper.WaitForWorkAround(6000);

            //Click on Click create button
            createPDFCategoriesHelper.ClickElement("ClickOnCreateBtn");
            createPDFCategoriesHelper.WaitForWorkAround(6000);

            //Enter Name
            createPDFCategoriesHelper.TypeText("EnterName", name);

            //Click on Save Button
            createPDFCategoriesHelper.ClickElement("ClickOnSaveBtn");
            createPDFCategoriesHelper.WaitForWorkAround(6000);

            //Verify text present
            createPDFCategoriesHelper.VerifyPageText("Category Created Successfully");

            //Clcik on Delete
            createPDFCategoriesHelper.SearchAndClick(name);
            createPDFCategoriesHelper.AcceptAlert();
            createPDFCategoriesHelper.ClickDisplayed("//a[@title='Save']");
            createPDFCategoriesHelper.WaitForWorkAround(4000);
             //   GetWebDriver().Navigate().Refresh();

               createPDFCategoriesHelper.VerifyPageText("Category Replaced Successfully.");
        }
        public void createLeadErrrorMessage()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var leadNewSkinHelper = new LeadNewSkinHelper(GetWebDriver());

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/leads/create");

            //Verify title
            VerifyTitle("Create a Lead");

            //Verify no error message displayed
            loginHelper.VerifyTextNotAvailable("A Lead already exists with the same Company name/Contact Name/Phone Number. Would you like to Merge or Duplicate the Lead?");
        }
Exemplo n.º 8
0
        public void createPDFPackage()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var pDFTemplateAdminHelper = new PDFTemplateAdminHelper(GetWebDriver());

            //Variable random
            var name = "TESTCLIENT" + RandomNumber(1,999);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Redirect To Admin
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/admin");
            pDFTemplateAdminHelper.WaitForWorkAround(4000);

            //ClickOnPdfTab
            pDFTemplateAdminHelper.ClickElement("ClickOnPdfTab");

            //Redirect To
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/pdf_templates");
            pDFTemplateAdminHelper.WaitForWorkAround(2000);

            //cLICK ON pdf
            pDFTemplateAdminHelper.ClickElement("ClickCreatePackage");
            pDFTemplateAdminHelper.WaitForWorkAround(2000);

            //Enter pakage name
            pDFTemplateAdminHelper.TypeText("PackageName","Test Pakage");

            //Select Module
            pDFTemplateAdminHelper.Select("SelectModule", "20");
            pDFTemplateAdminHelper.WaitForWorkAround(3000);

            //Select
            pDFTemplateAdminHelper.Select("SelectPDFTemplate", "8760");
            pDFTemplateAdminHelper.WaitForWorkAround(3000);

            //SelectCategoryPackage
            pDFTemplateAdminHelper.Select("SelectCategoryPackage", "336");

            //Save PDF Package
            pDFTemplateAdminHelper.ClickElement("SavePDFPakage");
            pDFTemplateAdminHelper.WaitForWorkAround(3000);
        }
Exemplo n.º 9
0
        public void tabsNotBroken()
        {
            string[] username = null;
            string[] password = null;
            string[] log = null;
            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username2");
            password = oXMLData.getData("settings/Credentials", "password2");
            log = oXMLData.getData("settings/URL", "logout");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var partnerAgentHelperNewSkin = new PartnerAgentHelperNewSkin(GetWebDriver());

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Verify tabs not broken
            partnerAgentHelperNewSkin.verifyNotBroken();

            //Logout from the application
            GetWebDriver().Navigate().GoToUrl(log[0]);
        }
Exemplo n.º 10
0
        public void createUserError1()
        {
            string[] username = null;
            string[] password = null;
            string[] log = null;
            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");
            log = oXMLData.getData("settings/URL", "logout");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var partnerAgentHelperNewSkin = new PartnerAgentHelperNewSkin(GetWebDriver());

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");

            //Go to Create user page
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/users/create");

            //Verify title
            VerifyTitle("Create User");

            //Select User type
            partnerAgentHelperNewSkin.SelectByText("Usertype", "Employee");

            //Click on Create new
            partnerAgentHelperNewSkin.ClickElement("UserCreate");

            //Enter first name
            partnerAgentHelperNewSkin.TypeText("UserFirstName", "Aslam");

            //Enter last Name
            partnerAgentHelperNewSkin.TypeText("UserLastName", "Khan");

            //Enter existing user name
            partnerAgentHelperNewSkin.TypeText("Userusername", username[0]);

            //Enter primary email
            partnerAgentHelperNewSkin.TypeText("UserEmail", "*****@*****.**");

            //Click on 'Save' button
            partnerAgentHelperNewSkin.ClickElement("UserSave");

            //Wait for text
            partnerAgentHelperNewSkin.WaitForText("This username already taken", 50);

            //Verify error not displayed
            partnerAgentHelperNewSkin.VerifyTextNotPresent("Internal server error page");

            //Logout from the application
            GetWebDriver().Navigate().GoToUrl(log[0]);
        }
Exemplo n.º 11
0
        public void verifyMyAccount()
        {
            string[] username = null;
            string[] password = null;
            string[] log = null;
            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");
            log = oXMLData.getData("settings/URL", "logout");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var partnerAgentHelperNewSkin = new PartnerAgentHelperNewSkin(GetWebDriver());

            //Verify title
            VerifyTitle("Login");

            //Click on Verify my account
            partnerAgentHelperNewSkin.ClickElement("VerifyAccount");

            //Enter username
            partnerAgentHelperNewSkin.TypeText("VerifyUsername", "aslamKhan");

            //Click on V
            partnerAgentHelperNewSkin.ClickElement("VerifyBody");

            //Verify error not displayed
            partnerAgentHelperNewSkin.VerifyTextNotPresent("Please include an '@' in the email address");
        }
Exemplo n.º 12
0
        public void pDFImportError()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username2");
            password = oXMLData.getData("settings/Credentials", "password2");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var pDFTemplateAdminHelper = new PDFTemplateAdminHelper(GetWebDriver());

            //Variable random
            var name = "TESTCLIENT" + RandomNumber(1,999);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //ClickOnPdfTab
            pDFTemplateAdminHelper.ClickElement("ClickOnPdfTab");

            //Redirect To
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/pdf_templates");
            pDFTemplateAdminHelper.WaitForWorkAround(2000);

            //Redirect To Import
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/pdf_templates/import");

            //ChooseModule
            pDFTemplateAdminHelper.Select("ChooseModule", "20");

            var path = GetPathToFile() + "2.pdf";

            //bROWSER
            pDFTemplateAdminHelper.UploadFile("//*[@id='PdfTemplatePdfFile']", path);

            //Click import
            pDFTemplateAdminHelper.ClickElement("ClickOnImport");
            pDFTemplateAdminHelper.WaitForWorkAround(10000);

            //Select tab
            pDFTemplateAdminHelper.SelectByText("Tab", "Business Details");
            pDFTemplateAdminHelper.WaitForWorkAround(5000);

            //Verify fields availble under section
            pDFTemplateAdminHelper.SelectByText("Section", "Merchant Account Data");
            pDFTemplateAdminHelper.WaitForWorkAround(5000);

            //Verify fields under fields
            pDFTemplateAdminHelper.SelectByText("Fields", "Merchant Type");
        }
Exemplo n.º 13
0
        public void verifyMyAccount()
        {
            //Initializing the objects
            LoginHelper loginHelper = new LoginHelper(GetWebDriver());
            ContactUsHelper contactUsHelper = new ContactUsHelper(GetWebDriver());

            //Login with blank username and password
             //   Login("", "");
              //  Console.WriteLine("Logged in as: " + "" + " / " + "");

            //Verify Page title
            VerifyTitle("Login");

            //Click on Contact Us
            contactUsHelper.ClickElement("VerifyAccountLink");

            //Enter Email
            contactUsHelper.TypeText("UserVerificationEmail", "*****@*****.**");

            //Click on Send Email btn
            contactUsHelper.ClickElement("EmailVerifyBtn");
            contactUsHelper.WaitForWorkAround(3000);

                contactUsHelper.AcceptAlert();

            //Capture screenshot fot the screen
            TakeScreenshot("ForgetPassword");
        }
        // [TestMethod]
        public void checkDownLoadedFileFormat()
        {
            string[] username = null;
            string[] password = null;

            XMLParse oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            LoginHelper loginHelper = new LoginHelper(GetWebDriver());
            AddDocumentAdminHelper addDocumentAdminHelper = new AddDocumentAdminHelper(GetWebDriver());

            // Variable
            var Proname = "Product" + RandomNumber(100, 999);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click On  Admin
            addDocumentAdminHelper.RedirectToAdmin();

               //Redirect to client page
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/clients");

            //Verify Title
            VerifyTitle("Clients");

            //Export as CSV
            addDocumentAdminHelper.ExportAs("CSV");

            var user = addDocumentAdminHelper.CurrentUser();

            //Get newly created file name from downloads folder
            var newfilename = addDocumentAdminHelper.Getnewfilename(new DirectoryInfo(@"C:\" + user + @"s\" + user + @"\Downloads\"));

            var filepath = @"C:\" + user + @"s\" + user + @"\Downloads\" + newfilename.ToString();

            //Verify downloaded file extention
            addDocumentAdminHelper.verifyDownloadedExtention("csv", filepath);

            //Export as Excel
            addDocumentAdminHelper.ExportAs("Excel");

            //Get newly created file name from downloads folder
            newfilename = addDocumentAdminHelper.Getnewfilename(new DirectoryInfo(@"C:\" + user + @"s\" + user + @"\Downloads\"));

            filepath = @"C:\" + user + @"s\" + user + @"\Downloads\" + newfilename.ToString();

            //Verify downloaded file extention
            addDocumentAdminHelper.verifyDownloadedExtention("xls", filepath);
        }
Exemplo n.º 15
0
        public void createGroups()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var createOfficeGrpAdminHelper = new CreateOfficeGrpAdminHelper(GetWebDriver());

            // Variable
            var name = "Test" + RandomNumber(1, 99);
            var email = "Test" + RandomNumber(1, 999) + "@gmail.com.com";

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click On  Admin
            createOfficeGrpAdminHelper.RedirectToAdmin();

            //##################  Redirect To Url

            //Redirect To URL
            createOfficeGrpAdminHelper.RedirectToPage();

            //Verify title
            VerifyTitle("Groups");

            //################################# Create Master Category #############################################

            // Click On Create
            createOfficeGrpAdminHelper.ClickElement("ClickOnCreate");

            //Verify title
            VerifyTitle("Create a Group");

            //Enter Group Name
            createOfficeGrpAdminHelper.TypeText("GrpName", name);

            //Enter Description
            createOfficeGrpAdminHelper.TypeText("Description", "THIS IS TEST DESCRIPTION");

            //cLICK on Save
            createOfficeGrpAdminHelper.ClickElement("ClickOnSave");

            //Wait for text
            createOfficeGrpAdminHelper.WaitForText("Group has been saved.", 30);
        }
Exemplo n.º 16
0
        public void pDFTemplatesPerminsions()
        {
            string[] username = null;
            string[] password = null;

            XMLParse oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var clientBugsHelper = new ClientBugsHelper(GetWebDriver());

            // Variable
            var name = "Test" + RandomNumber(1,99);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //#######################  MOVE HOVER TO THE WELCOME
            //Click on Move over
              //  clientBugsHelper.ClickElement("MouserHoverWelcome");

            //Click On  Admin
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selenium_corp/selenium_office/admin");

            //################################# PDF TEMPLATE TAB #############################################

            //Click on Terminal And Equipment Tab
            clientBugsHelper.ClickElement("ClickOnPDFTab");

            //Redirect
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selenium_corp/selenium_office/pdf_templates");

            //Click on PDF
            clientBugsHelper.ClickElement("ClickPDF");

            //Click On Permisions
            clientBugsHelper.ClickElement("ClickOnPermisions");
            clientBugsHelper.WaitForWorkAround(3000);

            //Click On None Of These
            clientBugsHelper.ClickElement("ClickOnNoneOfThese");

            //Click on Updtae
            clientBugsHelper.ClickElement("ClickOnUpdate");
            clientBugsHelper.WaitForWorkAround(2000);

            //Verify Text
            clientBugsHelper.VerifyPageText("Pdf Permissions Updated Successfully.");
        }
Exemplo n.º 17
0
        public void importClientsFromCSV()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var clientBugsHelper = new ClientBugsHelper(GetWebDriver());

            //Variable

            var FirstName = "Test" + RandomNumber(1, 99);
            var LastName = "Tester" + RandomNumber(1, 99);
            var Number = "12345678" + RandomNumber(10, 99);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click on Clients in Topmenu
            clientBugsHelper.ClickElement("ClientTab");
            clientBugsHelper.WaitForElementPresent("ClickOnImport", 20);

            //Click On Import
            clientBugsHelper.ClickElement("ClickOnImport");
            clientBugsHelper.WaitForWorkAround(2000);

            //Upload
            var Path = GetPathToFile() + "clientsamples(2).csv";
            clientBugsHelper.uploadCSVClient("SelectFile", Path);
            clientBugsHelper.WaitForWorkAround(3000);

            //Click On Import
            clientBugsHelper.ClickElement("ClickOnImportClint");
            clientBugsHelper.WaitForWorkAround(3000);

            //Select Client Import
            //  clientBugsHelper.Select("SelectClientImport","47");
            clientBugsHelper.WaitForWorkAround(3000);

            //Residual Import Sel
            //clientBugsHelper.Select("ResidualImportSel", "");

            //ClickImprtProcess
            clientBugsHelper.ClickElement("ClickImprtProcess");
            clientBugsHelper.WaitForWorkAround(10000);
        }
Exemplo n.º 18
0
        public void createLanguage()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var createLanguageHelper = new CreateLanguageHelper(GetWebDriver());

            //Variable
            var mail = "Test" + RandomNumber(1, 99) + "@yopmail.com";
            var numb = "12345678" + RandomNumber(10, 99);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Redirect To Language
            createLanguageHelper.redirectToPage();

            //Verify title
            VerifyTitle("Languages");

            //Click On Create Btn
            createLanguageHelper.ClickElement("ClickOnCreateBtn");

            //Enter Language Name
            var lang = "AA_Lang" + RandomNumber(99,999);
            createLanguageHelper.WaitForWorkAround(5000);
            createLanguageHelper.TypeText("EnterName", lang);

            //Clcik on Master Data
            createLanguageHelper.ClickElement("ClickSave");

            //Clcik on Edit language
            createLanguageHelper.ClickElement("ClickOnEditLanguage");

            //Enter Language Name
            var Elang = "AAA" + RandomNumber(1,99);
            createLanguageHelper.TypeText("EnterLanguage", Elang);

            //ClickOn Edit Save Button
            createLanguageHelper.ClickElement("ClickOnSaveBtn");

            //Click On Del Lang
            createLanguageHelper.ClickElement("ClickOnDelLang");
        }
        public void verifyAddAnotherVersionDisplay()
        {
            string[] username = null;
            string[] password = null;

            XMLParse oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var equiomentHelperAdmin = new EquiomentHelperAdmin(GetWebDriver());

            //Variable
            String  name = "Test" + RandomNumber(1,99);
            String Id = "12345" + RandomNumber(1, 99);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //#######################  MOVE HOVER TO THE WELCOME
            //Click on Move over
            equiomentHelperAdmin.ClickElement("MoveHover");

            //Click On  Admin
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/admin");

            //################################# Terminal And Equipment Tab #############################################

            //Click on Terminal And Equipment Tab
            equiomentHelperAdmin.ClickElement("ClickOnEquipmentTab");

            //##################  Redirect To Url

            //Redirect To URL
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/equipment");

            //################################# Create Equipments #############################################

            // Click On Create
            equiomentHelperAdmin.ClickElement("ClickOnCreate");
            equiomentHelperAdmin.WaitForWorkAround(3000);

            //Click on Add Another
            equiomentHelperAdmin.ClickElement("ClickAddAnother");

            //ClickAddAnother
            equiomentHelperAdmin.ClickElement("ClickAddAnother");
            equiomentHelperAdmin.WaitForWorkAround(3000);
        }
Exemplo n.º 20
0
        public void checkFilter()
        {
            string[] username = null;
            string[] password = null;
            string[] log = null;
            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");
            log = oXMLData.getData("settings/URL", "logout");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var partnerAgentHelperNewSkin = new PartnerAgentHelperNewSkin(GetWebDriver());

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Go to Detals payout page
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/rir/detailed_payouts");

            //Verify title
            VerifyTitle("Residual Income - Payouts");

            //Open on advanced filter
            partnerAgentHelperNewSkin.ClickElement("Advance");

            //Verify title
            VerifyTitle("Residual Income - Payouts");

            //Get count of available item in the Available Columns

            //Get Count of available item in the Display Columns

            //Go to the transaction page
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/rir/payout_summary");

            //Verify title
            VerifyTitle("Payouts Summary");

            //Click on View transaction button
            partnerAgentHelperNewSkin.ClickElement("ViewTrans");

            //Verify title
            VerifyTitle("Residual Income Import Transactions");

            //Open on advanced filter
            partnerAgentHelperNewSkin.ClickElement("Advance");

            //Logout from the application
            GetWebDriver().Navigate().GoToUrl(log[0]);
        }
        public void systemSchedularCreateNewJob()
        {
            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var systemCorpHelper = new SystemCorpHelper(GetWebDriver());
            var loginAsCorpHelper = new LoginAsCorpHelper(GetWebDriver());

            //Variable
            var AddressType = "Test" + RandomNumber(1,99);
            var Test = "New" + GetRandomNumber();

            //Login with valid credential  Username
            loginAsCorpHelper.TypeText("EnterUsername", "selcorp");

            //Login with valid credential password
            loginAsCorpHelper.TypeText("EnterPassword", "seWelcome2");

            //Click On Login Button
            loginAsCorpHelper.ClickElement("ClickOnLoginButton");
            loginAsCorpHelper.WaitForWorkAround(3000);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click on Residual Income tab
            systemCorpHelper.ClickElement("SystemTab");

            //Redirect To PickList
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selenium_corp/schedulers");
            systemCorpHelper.WaitForWorkAround(4000);

            //Click on Create Schedular button
            systemCorpHelper.ClickElement("ClickOnCreatebtn");

            //Enter Job Name
            systemCorpHelper.TypeText("JobName","Test");
            systemCorpHelper.WaitForWorkAround(2000);

            //Enter Job   //No Dropdown content available
            systemCorpHelper.Select("Job", "Testing");

            //Select interval
            systemCorpHelper.Select("Interval", "30");

            //Select Status
            systemCorpHelper.Select("Status", "0");

            //Everyday
            systemCorpHelper.ClickElement("Everyday");

            //Save Schedular
            systemCorpHelper.ClickElement("SaveSchedular");
            systemCorpHelper.WaitForWorkAround(4000);
        }
Exemplo n.º 22
0
        public void createOfficeTeams()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var createOfficeTeamAdmin = new CreateOfficeTeamAdmin(GetWebDriver());

            // Variable
            var name = "Testing" + RandomNumber(1, 99);
            var email = "Test" + RandomNumber(1, 999) + "@gmail.com.com";

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click On  Admin
            createOfficeTeamAdmin.RedirectToAdmin();

            //Redirect To URL
            createOfficeTeamAdmin.RedirectToPage();

            //Verify Title
            VerifyTitle("Teams");

            //################################# Create Master Category #############################################

            // Click On Create
            createOfficeTeamAdmin.ClickElement("ClickOnCreate");

            //Wait
            createOfficeTeamAdmin.WaitForWorkAround(3000);

            //Enter Name
            createOfficeTeamAdmin.TypeText("TeamName", name);

            //Select Department
            createOfficeTeamAdmin.Selectbytext("SelectDepartment", "IT");

            //cLICK on Save
            createOfficeTeamAdmin.ClickElement("ClickOnSave");

            //Wait for text
            createOfficeTeamAdmin.WaitForText("Team has been saved.", 30);
        }
        public void fieldDictionaryFields()
        {
            string[] username = null;
            string[] password = null;
            string[] log = null;
            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");
            log = oXMLData.getData("settings/URL", "logout");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var partnerAgentHelperNewSkin = new PartnerAgentHelperNewSkin(GetWebDriver());

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Go to Field Dictionary Fields page
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/fields");

            //Verify Title
            VerifyTitle("Field Management");

               //Select Module
            partnerAgentHelperNewSkin.SelectByText("FSModule", "Clients");

            partnerAgentHelperNewSkin.WaitForWorkAround(3000);

            //Select Tab
            partnerAgentHelperNewSkin.SelectByText("FSTab", "Company Details");

            //Click on Search Button
            partnerAgentHelperNewSkin.ClickElement("FSSearch");

            //Verify field availabe
            partnerAgentHelperNewSkin.verifyElementPresent("FSFilter");

            //Enter  mail
            partnerAgentHelperNewSkin.TypeText("FSFilter", "Mail");

            //Click on Mail
            partnerAgentHelperNewSkin.ClickElement("FSMail");

            //Verify Manage button available
            partnerAgentHelperNewSkin.verifyElementPresent("FSManage");

            //Log out from the application
            GetWebDriver().Navigate().GoToUrl(log[0]);
        }
Exemplo n.º 24
0
        public void addNotesAdmin()
        {
            string[] username = null;
            string[] password = null;

            XMLParse oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            LoginHelper loginHelper = new LoginHelper(GetWebDriver());
            ClientsHelper clientHelper = new ClientsHelper(GetWebDriver());
            AddNotesAdminHelper addNotesAdminHelper = new AddNotesAdminHelper(GetWebDriver());

            // Variable
            String name = "Testing Subject" + RandomNumber(1, 99);
            String email = "Test" + RandomNumber(1,999)+ "@gmail.com";

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click on Clients in Topmenu
            //            clientHelper.clickClients();

            //Click to open client info
               //         clientHelper.OpenClient();

            //Click On  Admin
            addNotesAdminHelper.RedirectToAdmin();

            //################################# Corprate TAB #############################################

            //Click on Terminal And Equipment Tab
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/notes/create");

            //verify title
            VerifyTitle("Create a New Note");

            //################################# ADD NOTE #############################################

            //Enter Name
            addNotesAdminHelper.TypeText("EnterSubjuct", name);

            //Select Department
            //addNotesAdminHelper.TypeText("EnterDescription", "This is testing description notes");

            //cLICK on Save
            addNotesAdminHelper.ClickElement("ClickOnSave");
            addNotesAdminHelper.WaitForText("Note saved successfully.",30);
        }
        public void createProcessorNewSkin()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username2");
            password = oXMLData.getData("settings/Credentials", "password2");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var clientHelperNewSkin = new ClientHelperNewSkin(GetWebDriver());

            //VARIABLE
            var name = "TestEmployee" + GetRandomNumber();

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click on Agent in Topmenu
               // clientHelperNewSkin.ClickElement("ClickOnMasterDataCorp");

               //ClickOnCreateClient
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/masterdata/processor_types");
               clientHelperNewSkin.WaitForWorkAround(3000);

            //Click on Create
               clientHelperNewSkin.ClickElement("ClickOnCreateBtn");
               clientHelperNewSkin.WaitForWorkAround(3000);

               //Click save
               clientHelperNewSkin.ClickElement("ClickOnSavePro");
               clientHelperNewSkin.WaitForWorkAround(3000);

               //EnterProcessorName
               var procnam = "TestPro" + RandomNumber(1,99);
               clientHelperNewSkin.TypeText("EnterProcessorName",procnam);

               //EnterProcessorName
               var Code = "1" + RandomNumber(1, 99);
               clientHelperNewSkin.TypeText("EnterCode", Code);

            //Click save
               clientHelperNewSkin.ClickElement("ClickOnSavePro");
               clientHelperNewSkin.WaitForWorkAround(3000);

            //Verify
               clientHelperNewSkin.VerifyPageText("Processor is successfully created!!");
        }
Exemplo n.º 26
0
        public void editThemeAdmin()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var themeAdminHelper = new ThemeAdminHelper(GetWebDriver());

            //VARIABLE
            var name = "TestEmployee" + GetRandomNumber();

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //ClickOnCreateClient
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/admin");
            themeAdminHelper.WaitForWorkAround(3000);

            //Click on Agent in Topmenu
            themeAdminHelper.ClickElement("ClickOnSystemTab");

            //Redirect  To Theme
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/themes");
            themeAdminHelper.WaitForWorkAround(3000);

            //EnterThemeSearch
            themeAdminHelper.TypeText("EnterThemeSearch", "test234");
            themeAdminHelper.WaitForWorkAround(3000);

            //SelectFontSize
            themeAdminHelper.ClickElement("ClickEditTheme");
            themeAdminHelper.WaitForWorkAround(3000);

            //SelectFontSize
            themeAdminHelper.SelectDropDownByText("//*[@id='ThemeOption27Value']", "10px");

            //CLickSaveButton
            themeAdminHelper.ClickElement("CLickSaveButton");
            themeAdminHelper.WaitForWorkAround(3000);

            //Verify
            themeAdminHelper.VerifyPageText("Theme Configuration has been updated.");
            themeAdminHelper.WaitForWorkAround(3000);
        }
Exemplo n.º 27
0
        public void checkProcessor()
        {
            string[] username = null;
            string[] password = null;

            XMLParse oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            LoginHelper loginHelper = new LoginHelper(GetWebDriver());
            ClientsHelper clientHelper = new ClientsHelper(GetWebDriver());
            AddDocumentAdminHelper addDocumentAdminHelper = new AddDocumentAdminHelper(GetWebDriver());

            // Variable
            var Proname = "Product" + RandomNumber(100, 999);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click On  Admin
            addDocumentAdminHelper.RedirectToAdmin();

            //Redirect to the master Processors page
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/processor_types");

            //verify title
            VerifyTitle("Master Processors");

            //Get all processor count
            int processcount = addDocumentAdminHelper.GetProcessorCount("ProcessTable");

            //Get all processor
            string[] processor = addDocumentAdminHelper.GetAllProcessor("ProcessTable");

            //Redirect to the Create client page
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/clients/create");

            //Verify title
            VerifyTitle("Create a Client");

            //Click on Bussiness details
            addDocumentAdminHelper.ClickElement("Bussiness");

            //Verify Count
            addDocumentAdminHelper.VerifyProcessCount("ProcessDropdown", processcount);

            //Verify all processor
            addDocumentAdminHelper.VerifyAllProcessor("ProcessDropdown", processor);
        }
        public void allAgentDisplayePage()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var saleAgentRevenueAdjustmentHelper = new SaleAgentRevenueAdjustmentHelper(GetWebDriver());

            //Variable random
            var name = "TESTCLIENT" + RandomNumber(1,999);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click on Agent in Topmenu
            saleAgentRevenueAdjustmentHelper.ClickElement("ClickOnAgentTab");
            saleAgentRevenueAdjustmentHelper.WaitForWorkAround(3000);

            //################################# CREATE A agent   #############################################

            //Click on Click On Partner Agent
            GetWebDriver().Navigate().GoToUrl("https://www.pegasus-test.com/selcorp/seloffice/agents");
               saleAgentRevenueAdjustmentHelper.WaitForWorkAround(3000);

            //Verify text
               VerifyTitle("selOffice's All Agents");
               saleAgentRevenueAdjustmentHelper.WaitForWorkAround(2000);

            //Select SelectUserType
            saleAgentRevenueAdjustmentHelper.Select("SelectUserType","Employee");
            saleAgentRevenueAdjustmentHelper.WaitForWorkAround(2000);

             //Select SelectUserType
            saleAgentRevenueAdjustmentHelper.Select("SelectUserType","1099 Sales Agent");
            saleAgentRevenueAdjustmentHelper.WaitForWorkAround(2000);

             //Select SelectUserType
            saleAgentRevenueAdjustmentHelper.Select("SelectUserType","Partner Agent");
            saleAgentRevenueAdjustmentHelper.WaitForWorkAround(2000);

             //Select SelectUserType
            saleAgentRevenueAdjustmentHelper.Select("SelectUserType","Partner Association");
            saleAgentRevenueAdjustmentHelper.WaitForWorkAround(2000);
        }
Exemplo n.º 29
0
        public void sendEmailFromOfficeCorp()
        {
            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            // Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var editOfficeHelper = new EditOfficeHelper(GetWebDriver());

            //Variable random

            var username = "******" + GetRandomNumber();
            var name = "Test" + RandomNumber(1, 99);

            //Login with valid username and password
            editOfficeHelper.TypeText("EnterUsername", "selcorp");

            //Login with valid username and password
            editOfficeHelper.TypeText("EnterPassword", "seWelcome2");

            //Login Button
            editOfficeHelper.ClickElement("ClickOnLoginButtojn");

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click on Agent in Topmenu
            editOfficeHelper.ClickElement("ClickOnOfficeTab");

            //################################# CREATE A agent   #############################################

            //Redirect to Office
            editOfficeHelper.redirectToPage();

            //Enter Name To Search Office
            editOfficeHelper.TypeText("EnterNameToSrch", "Selenium Office");
            editOfficeHelper.WaitForWorkAround(3000);

            //Click on Delete
            editOfficeHelper.ClickElement("ClickOnOffice");

            //Click Delete to confirm
            editOfficeHelper.ClickElement("ClickOfficeEmail");

            //Enter Subject
            editOfficeHelper.TypeText("EnterSubject", "Testing Email");

            //Enter Message
            editOfficeHelper.TypeText("Message", "This is testing message");

            //Click Send Button
            editOfficeHelper.ClickElement("SendEmailBtn");
            editOfficeHelper.WaitForWorkAround(2000);
            editOfficeHelper.VerifyPageText("Email Sent Successfully.");
        }
Exemplo n.º 30
0
        public void createProductCategory()
        {
            string[] username = null;
            string[] password = null;

            var oXMLData = new XMLParse();
            oXMLData.LoadXML("../../Config/ApplicationSettings.xml");

            username = oXMLData.getData("settings/Credentials", "username");
            password = oXMLData.getData("settings/Credentials", "password");

            //Initializing the objects
            var loginHelper = new LoginHelper(GetWebDriver());
            var clientHelper = new ClientsHelper(GetWebDriver());
            var createProductsCategoryHelper = new CreateProductsCategoryHelper(GetWebDriver());

            //Variable
            var name = "Test" + RandomNumber(99, 999);

            //Login with valid username and password
            Login(username[0], password[0]);
            Console.WriteLine("Logged in as: " + username[0] + " / " + password[0]);

            //Verify Page title
            VerifyTitle("Dashboard");
            Console.WriteLine("Redirected at Dashboard screen.");

            //Click On  Admin
            createProductsCategoryHelper.RedirectToAdmin();

            //Redirect To URL
            createProductsCategoryHelper.RedirectToPage();

            //Verify title
            VerifyTitle("Product Categories");

            //################################# Create Equipments #############################################

            // Click On Create
            createProductsCategoryHelper.ClickElement("ClickOnCreate");

            createProductsCategoryHelper.WaitForWorkAround(3000);

            //Enter Name
            createProductsCategoryHelper.TypeText("Name", name);

            //######################## CLICK ON SAVE BUTTON  ########################################
            // Click on Save button
            createProductsCategoryHelper.ClickElement("SaveBtn");

            //wait for text
            createProductsCategoryHelper.WaitForText("Category Created Successfully", 30);

            //Search and click
            createProductsCategoryHelper.SearchAnclick(name);
        }