Beispiel #1
0
        internal void EditEducation()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            // Refresh the page
            Driver.driver.Navigate().Refresh();

            //Click on education
            //Click on Education button
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[3]", 10000);
            EducationBtn.Click();

            //Click on education to be edit
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000);
            EduToSel.Click();

            //Click on edit education button
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[6]/span[1]/i", 10000);
            EditEduBtn.Click();

            //Update education
            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "title", 10000);
            SelectTitle.Click();
            new SelectElement(SelectTitle).SelectByText(ExcelLibHelper.ReadData(3, "Title"));
            Thread.Sleep(1000);
        }
Beispiel #2
0
        internal void ResponseRequests()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "ManageRequest");
            // Start the Reports
            CommonMethods.ExtentReports();
            Thread.Sleep(1000);
            CommonMethods.test = CommonMethods.extent.StartTest("Accept Or Decline");
            //Accept or Declane request

            if (ExcelLibHelper.ReadData(2, "ReceviedRequest") == "Accept")
            {
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='received-request-section']/div[2]/div[1]/table/tbody/tr[1]/td[8]/button[1]", 10000);
                AcceptRequest.Click();
            }
            else if (ExcelLibHelper.ReadData(2, "ReceviedRequest") == "Decline")
            {
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='received-request-section']/div[2]/div[1]/table/tbody/tr[1]/td[8]/button[2]", 10000);
                DeclineRequest.Click();
            }

            //Complete request
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='received-request-section']/div[2]/div[1]/table/tbody/tr[3]/td[8]/button", 10000);
            CompleteRequest.Click();
            CommonMethods.test.Log(LogStatus.Info, "Responded to received request successfully");
        }
        internal void EditLanguage()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            // Refresh the page
            Driver.driver.Navigate().Refresh();


            //Click on language
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[1]", 10000);
            LangBtn.Click();

            //Click on language to edit
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000);
            LangToSel.Click();

            //Click on edit language button
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[3]/span[1]/i", 10000);
            EditLangBtn.Click();

            //Update the language
            //Update language level
            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "level", 10000);
            ChooseLevel.Click();

            new SelectElement(ChooseLevel).SelectByText(ExcelLibHelper.ReadData(3, "LanguageLevel"));
            Thread.Sleep(1000);
        }
        internal void VerifyLanguage()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");

            //verify language
            try
            {
                //Start the Reports
                CommonMethods.ExtentReports();
                Thread.Sleep(1000);
                CommonMethods.test = CommonMethods.extent.StartTest("Add Language");

                //Verify Language Name
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[1]", 10000);
                LangBtn.Click();
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000);
                var lastRowLanguageName = Driver.driver.FindElement(By.XPath("//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[1]")).Text;
                Assert.That(lastRowLanguageName, Is.EqualTo(ExcelLibHelper.ReadData(2, "Language")));

                //Verify Language Level
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[2]", 10000);
                var lastRowLanguageLevel = Driver.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[2]")).Text;
                Assert.That(lastRowLanguageLevel, Is.EqualTo(ExcelLibHelper.ReadData(2, "LanguageLevel")));
                CommonMethods.test.Log(LogStatus.Pass, "Test Passed, Language Added Successfully");
                SaveScreenShotClass.SaveScreenshot(Driver.driver, "LanguageAdded");
            }
            catch (Exception ex)
            {
                CommonMethods.test.Log(LogStatus.Fail, "Test Failed");
                Assert.Fail("Test failed to verify Entering Language", ex.Message);
            }
        }
Beispiel #5
0
        internal void UpdateEducation()
        {
            //Click on update education button
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody/tr/td/div[3]/input[1]", 10000);

            UpdateEduBtn.Click();
        }
Beispiel #6
0
        internal void EnterSkill()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            // Refresh the page
            Driver.driver.Navigate().Refresh();
            //Click on skill
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[2]", 10000);
            SkillBtn.Click();

            //Click on add new skill
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/thead/tr/th[3]/div", 10000);
            AddNewSkillBtn.Click();

            //Add new skill

            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "name", 10000);
            AddSkillBox.Click();
            AddSkill.SendKeys(ExcelLibHelper.ReadData(2, "Skill"));

            //Add skill level
            AddSkillLevel.Click();
            new SelectElement(AddSkillLevel).SelectByText(ExcelLibHelper.ReadData(2, "SkillLevel"));
            Thread.Sleep(1000);
        }
Beispiel #7
0
        internal void VerifyEditedDescription()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");


            //Verify edited description
            try
            {
                //Start the Reports
                CommonMethods.ExtentReports();
                Thread.Sleep(1000);
                CommonMethods.test = CommonMethods.extent.StartTest("Edit Description");

                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/div/div/div/span", 10000);
                var description = Driver.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/div/div/div/span")).Text;
                Assert.That(description, Is.EqualTo(ExcelLibHelper.ReadData(3, "Description")));
                CommonMethods.test.Log(LogStatus.Pass, "Test Passed, Description Edited Successfully");
                SaveScreenShotClass.SaveScreenshot(Driver.driver, "DescriptionEdited");
            }
            catch (Exception ex)
            {
                CommonMethods.test.Log(LogStatus.Fail, "Test Failed", ex.Message);
            }
        }
        internal void DeleteLanguage()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            try
            {
                //Start the Reports
                CommonMethods.ExtentReports();
                Thread.Sleep(1000);
                CommonMethods.test = CommonMethods.extent.StartTest("Delete Language");

                //Click on language
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[1]", 10000);
                LangBtn.Click();

                //Click on language to delete
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000);
                LangToSel.Click();

                //Click on delete language
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[2]/div/div[2]/div/table/tbody[last()]/tr/td[3]/span[2]/i", 20000);
                DeleteLangBtn.Click();
                CommonMethods.test.Log(LogStatus.Pass, "Test Passed, Language Deleted Successfully");
                SaveScreenShotClass.SaveScreenshot(Driver.driver, "LanguageDeleted");
            }
            catch (Exception ex)
            {
                CommonMethods.test.Log(LogStatus.Fail, "Test Failed", ex.Message);
            }
        }
Beispiel #9
0
        internal void EnterCertification()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            // Refresh the page
            Driver.driver.Navigate().Refresh();

            //Click on Certifications
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[4]", 10000);
            CertificationBtn.Click();

            //Click on add new certifications
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/thead/tr/th[4]/div", 10000);
            AddNewCertiBtn.Click();

            //Input Certification
            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "certificationName", 10000);
            CertifiBtn.Click();
            CertifiName.SendKeys(ExcelLibHelper.ReadData(2, "Certificate"));

            //Input certification from
            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "certificationFrom", 10000);
            CertiFromBtn.Click();
            CertifiFrom.SendKeys(ExcelLibHelper.ReadData(2, "CertifiedFrom"));

            //Select year from drop down
            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "certificationYear", 10000);
            CertiYear.Click();
            new SelectElement(CertiYear).SelectByText(ExcelLibHelper.ReadData(2, "YearOfCertification"));;
            Thread.Sleep(1000);
        }
Beispiel #10
0
        internal void DeleteCertification()
        {
            // Refresh the page
            Driver.driver.Navigate().Refresh();

            //Delete Certification

            try
            {
                //Start the Reports
                CommonMethods.ExtentReports();
                Thread.Sleep(1000);
                CommonMethods.test = CommonMethods.extent.StartTest("Delete Certification");
                //Click on certification
                //Click on Certifications
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[4]", 10000);
                CertificationBtn.Click();

                //Click on certification to be deleted
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[1]", 10000);
                CertiToSel.Click();

                //Click on delete certification button
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[4]/span[2]", 20000);
                DeleteCertiBtn.Click();
                CommonMethods.test.Log(LogStatus.Pass, "Test Passed, Certification Deleted Successfully");
                SaveScreenShotClass.SaveScreenshot(Driver.driver, "CertificationDeleted");
            }

            catch (Exception ex)
            {
                CommonMethods.test.Log(LogStatus.Fail, "Test Failed", ex.Message);
            }
        }
Beispiel #11
0
        internal void EditCertification()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            // Refresh the page
            Driver.driver.Navigate().Refresh();

            //Click on certification
            //Click on Certifications
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[4]", 10000);
            CertificationBtn.Click();

            //Click on certification to be edit
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[1]", 10000);
            CertiToSel.Click();

            //Click on edit certification button
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[4]/span[1]/i", 10000);
            EditCertiBtn.Click();

            //Update certification
            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "certificationYear", 10000);
            CertiYear.Click();
            new SelectElement(CertiYear).SelectByText(ExcelLibHelper.ReadData(3, "YearOfCertification"));;
            Thread.Sleep(1000);
        }
Beispiel #12
0
        internal void VerifyEditedCertification()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            // Refresh the page
            Driver.driver.Navigate().Refresh();
            //verify updated certification
            //verify certification
            try
            {
                //Start the Reports
                CommonMethods.ExtentReports();
                Thread.Sleep(1000);
                CommonMethods.test = CommonMethods.extent.StartTest("Update Certification");


                //Jump to Certification tab
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[4]", 10000);
                CertificationBtn.Click();

                //Verify Certificate Year
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[3]", 10000);
                var lastRowCertificateYear = Driver.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[5]/div[1]/div[2]/div/table/tbody[last()]/tr/td[3]")).Text;
                Assert.That(lastRowCertificateYear, Is.EqualTo(ExcelLibHelper.ReadData(3, "YearOfCertification")));
                CommonMethods.test.Log(LogStatus.Pass, "Test Passed, Certification Updated Successfully");
                SaveScreenShotClass.SaveScreenshot(Driver.driver, "CertificationUpdated");
            }
            catch (Exception ex)
            {
                CommonMethods.test.Log(LogStatus.Fail, "Test Failed", ex.Message);
            }
        }
Beispiel #13
0
 internal void AddSkills()
 {
     //Click on add skill
     WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//input[@value='Add']", 10000);
     AddSkillBtn.Click();
     CommonMethods.test.Log(LogStatus.Info, "Added skill successfully");
 }
        internal void ValidateEditedDetails()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "ManageListing");
            // Refresh the page
            Driver.driver.Navigate().Refresh();

            //Validate edited data
            //Click on Manage Listing
            WaitHelpers.WaitForElementVisibility(Driver.driver, "LinkText", "Manage Listings", 10000);
            manageListingsLink.Click();
            Thread.Sleep(5000);
            //Click on view button
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "(//i[@class='eye icon'])[1]", 10000);
            view.Click();
            Driver.driver.Navigate().Refresh();
            try
            {
                //Start the Reports
                CommonMethods.ExtentReports();
                Thread.Sleep(1000);
                CommonMethods.test = CommonMethods.extent.StartTest("EditListing");

                WaitHelpers.WaitForElement(Driver.driver, "XPath", "//*[@id='service-detail-section']/div[2]/div/div[2]/div[1]/div[1]/div[2]/h1/span", 20000);
                var ViewValidation = Driver.driver.FindElement(By.XPath("//*[@id='service-detail-section']/div[2]/div/div[2]/div[1]/div[1]/div[2]/h1/span")).Text;
                Assert.That(ViewValidation, Is.EqualTo(ExcelLibHelper.ReadData(3, "Title")));
                CommonMethods.test.Log(LogStatus.Pass, "Listing Edited successfully");
                SaveScreenShotClass.SaveScreenshot(Driver.driver, "ListingUpdated");
            }
            catch (Exception ex)
            {
                Assert.Fail("verify the edited share skill page failed", ex.Message);
                CommonMethods.test.Log(LogStatus.Fail, "Unable to edit listing");
            }
        }
Beispiel #15
0
        internal void VerifyEditedSkill()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            // Refresh the page
            Driver.driver.Navigate().Refresh();
            //Verify updated skill
            try
            {
                //Start the Reports
                CommonMethods.ExtentReports();
                Thread.Sleep(1000);
                CommonMethods.test = CommonMethods.extent.StartTest("Edit skill");

                //Jump to Skill tab

                //Click on skill
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[2]", 10000);
                SkillBtn.Click();

                //Verify Skill Level
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[2]", 10000);
                var lastRowSkillLevel = Driver.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[2]")).Text;
                Assert.That(lastRowSkillLevel, Is.EqualTo(ExcelLibHelper.ReadData(3, "SkillLevel")));
                CommonMethods.test.Log(LogStatus.Pass, "Test Passed, Skill Updated Successfully");
                SaveScreenShotClass.SaveScreenshot(Driver.driver, "SkillUpdated");
            }
            catch (Exception ex)
            {
                CommonMethods.test.Log(LogStatus.Fail, "Test Failed");
                Assert.Fail("Test failed to verify updated Skills", ex.Message);
            }
        }
Beispiel #16
0
 internal void UpodateSkills()
 {
     //Click on update
     WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[1]/tr/td/div/span/input[1]", 10000);
     UpdateSkillBtn.Click();
     //CommonMethods.test.Log(LogStatus.Info, "Skill edited successfully");
 }
Beispiel #17
0
        internal void EditSkills()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            // Refresh the page
            Driver.driver.Navigate().Refresh();

            //Click on skill
            //Click on skill
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[2]", 10000);
            SkillBtn.Click();

            //Click on skill to be edited
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000);
            SkillToSel.Click();

            //Click on Edit skill
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[3]/div/div[2]/div/table/tbody[last()]/tr/td[3]/span[1]/i", 10000);
            EditSkill.Click();

            //Edit the skill
            //Add skill level
            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "level", 10000);
            AddSkillLevel.Click();
            new SelectElement(AddSkillLevel).SelectByText(ExcelLibHelper.ReadData(3, "SkillLevel"));
            Thread.Sleep(1000);
        }
        internal void VerifySkill()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "ShareSkill");
            //Verify share skill details

            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id=\"listing-management-section\"]/div[2]/div[1]/div[2]/button[2]", 10000);
            ManageLis.Click();
            Driver.driver.Navigate().Refresh();
            try
            {
                //Start the Reports
                CommonMethods.ExtentReports();
                Thread.Sleep(1000);
                CommonMethods.test = CommonMethods.extent.StartTest("Verify ShareSkill");

                WaitHelpers.WaitForElement(Driver.driver, "XPath", "//*[@id='listing-management-section']/div[2]/div[1]/div[1]/table/tbody/tr[1]/td[2]", 10000);
                var categorycheck = Driver.driver.FindElement(By.XPath("//*[@id='listing-management-section']/div[2]/div[1]/div[1]/table/tbody/tr[1]/td[2]")).GetAttribute("textContent");
                Assert.That(categorycheck, Is.EqualTo(ExcelLibHelper.ReadData(2, "Category")));

                WaitHelpers.WaitForElement(Driver.driver, "XPath", "//*[@id='listing-management-section']/div[2]/div[1]/div[1]/table/tbody/tr[1]/td[3]", 10000);
                var titlecheck = Driver.driver.FindElement(By.XPath("//*[@id='listing-management-section']/div[2]/div[1]/div[1]/table/tbody/tr[1]/td[3]")).GetAttribute("textContent");
                Assert.That(titlecheck, Is.EqualTo(ExcelLibHelper.ReadData(2, "Title")));
                CommonMethods.test.Log(LogStatus.Pass, "Test Passed, ShareSkill Verified Successfully");
                SaveScreenShotClass.SaveScreenshot(Driver.driver, "ShareSkillVerified");
            }
            catch (Exception ex)
            {
                CommonMethods.test.Log(LogStatus.Fail, "Test Failed", ex.Message);
            }
        }
        internal void SetPassword()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "SignIn");
            //Click on Name
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/div[1]/div[2]/div/span", 10000);
            NameBtn.Click();

            //Click on change password
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/div[1]/div[2]/div/span/div/a[2]", 10000);
            ChgPwdBtn.Click();
            Thread.Sleep(1000);
            //Enter old password
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "/html/body/div[4]/div/div[2]/form/div[1]/input", 10000);
            CurrentPwd.Click();
            CurrentPwd.SendKeys(ExcelLibHelper.ReadData(2, "NewPassword"));


            //Enter new password
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "/html/body/div[4]/div/div[2]/form/div[2]/input", 10000);
            NewPwd.Click();
            NewPwd.SendKeys(ExcelLibHelper.ReadData(2, "Password"));

            //Confirm new password
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "/html/body/div[4]/div/div[2]/form/div[3]/input", 10000);
            ConfirmNewPwd.Click();
            ConfirmNewPwd.SendKeys(ExcelLibHelper.ReadData(2, "Password"));
            Thread.Sleep(1000);
        }
 internal void Listings()
 {
     //Click on Manage Listing
     WaitHelpers.WaitForElementVisibility(Driver.driver, "LinkText", "Manage Listings", 10000);
     manageListingsLink.Click();
     Driver.driver.Navigate().Refresh();
     Thread.Sleep(1000);
 }
        internal void Search_skill()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "SearchSkill");

            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/div[1]/div[1]/input", 10000);
            SearchButton.Click();
            SearchButton.SendKeys(ExcelLibHelper.ReadData(2, "SearchSkill"));
        }
Beispiel #22
0
        internal void ChatsSent()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Chat");

            //Select chat box to enter data
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='chatTextBox']", 10000);
            EnterChat.Click();
            EnterChat.SendKeys(ExcelLibHelper.ReadData(2, "Message"));
            //EnterChat.SendKeys("Hi");
        }
Beispiel #23
0
 internal void NotificationUnSelectAll()
 {
     //Start the Reports
     CommonMethods.ExtentReports();
     Thread.Sleep(1000);
     CommonMethods.test = CommonMethods.extent.StartTest("UnSelect All");
     //UnSelect All
     WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='notification-section']/div[2]/div/div/div[3]/div[1]/div[2]", 10000);
     UnSelectAll.Click();
     CommonMethods.test.Log(LogStatus.Info, "Successfully Unselected all notifications");
     SaveScreenShotClass.SaveScreenshot(Driver.driver, "UnSelectAllNotification");
 }
        internal void EnterDetails()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");

            #region Availability

            //Click on availability edit
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[2]/div/div/div/div/div/div[3]/div/div[2]/div/span/i", 10000);
            AvailabilityTimeEdit.Click();

            //Click on availability dropdown
            AvailabilityTime.Click();

            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "availabiltyType", 10000);
            //select availability time
            new SelectElement(AvailabilityTime).SelectByText(ExcelLibHelper.ReadData(2, "AvailableTime"));
            CommonMethods.test.Log(LogStatus.Info, "Select the available time");

            #endregion

            #region Hour

            //click on hour edit
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[2]/div/div/div/div/div/div[3]/div/div[3]/div/span/i", 10000);
            HourEdit.Click();

            //click on houredit dropdown
            AvailabilityHour.Click();

            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "availabiltyHour", 10000);
            //select availability hour
            new SelectElement(AvailabilityHour).SelectByText(ExcelLibHelper.ReadData(2, "Hours"));
            CommonMethods.test.Log(LogStatus.Info, "Added hour successfully");

            #endregion

            #region EarnTarget
            //click on Target edit
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[2]/div/div/div/div/div/div[3]/div/div[4]/div/span/i", 10000);
            SalaryEdit.Click();

            //click on Target salary dropdown
            SalarySelect.Click();

            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "availabiltyTarget", 10000);
            //select salary
            new SelectElement(SalarySelect).SelectByText(ExcelLibHelper.ReadData(2, "EarnTarget"));
            CommonMethods.test.Log(LogStatus.Info, "Added Target successfully");
            Thread.Sleep(1000);
            #endregion
        }
Beispiel #25
0
 internal void NotificationDelete()
 {
     //Start the Reports
     CommonMethods.ExtentReports();
     Thread.Sleep(1000);
     CommonMethods.test = CommonMethods.extent.StartTest("Delete Notification");
     //Delete Notification
     WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='notification-section']/div[2]/div/div/div[3]/div[1]/div[3]/i", 10000);
     Delete.Click();
     Thread.Sleep(2000);
     CommonMethods.test.Log(LogStatus.Info, "Delete notification successfull");
     SaveScreenShotClass.SaveScreenshot(Driver.driver, "NotificationDelete");
 }
Beispiel #26
0
        internal void SuccesfullChats()
        {
            //Start the Reports
            CommonMethods.ExtentReports();
            Thread.Sleep(1000);
            CommonMethods.test = CommonMethods.extent.StartTest("SentChat");

            //Click on Send tab
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='btnSend']", 10000);
            clickSend.Click();
            CommonMethods.test.Log(LogStatus.Info, "Chat message sent successfully");
            SaveScreenShotClass.SaveScreenshot(Driver.driver, "Chat Successfully");
        }
Beispiel #27
0
        internal void VerifyEducation()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "Profile");
            //// Refresh the page
            //Driver.driver.Navigate().Refresh();
            //verify education
            try
            {
                //Start the Reports
                CommonMethods.ExtentReports();
                Thread.Sleep(1000);
                CommonMethods.test = CommonMethods.extent.StartTest("Add Education");

                //Jump to Education tab
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//div[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[1]/a[3]", 10000);
                EducationBtn.Click();

                //Verify Education Country
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[1]", 10000);
                var lastRowEducationCountry = Driver.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[1]")).Text;
                Assert.That(lastRowEducationCountry, Is.EqualTo(ExcelLibHelper.ReadData(2, "Country")));

                //Verify Education Name
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[2]", 10000);
                var lastRowEducationName = Driver.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[2]")).Text;
                Assert.That(lastRowEducationName, Is.EqualTo(ExcelLibHelper.ReadData(2, "University")));

                //Verify Education Title
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[3]", 10000);
                var lastRowEducationTitle = Driver.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[3]")).Text;
                Assert.That(lastRowEducationTitle, Is.EqualTo(ExcelLibHelper.ReadData(2, "Title")));

                //Verify Education Degree
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[4]", 10000);
                var lastRowEducationDegree = Driver.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[4]")).Text;
                Assert.That(lastRowEducationDegree, Is.EqualTo(ExcelLibHelper.ReadData(2, "Degree")));

                //Verify Education Graduation Year
                WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[5]", 10000);
                var lastRowEducationGraduationYear = Driver.driver.FindElement(By.XPath("//*[@id='account-profile-section']/div/section[2]/div/div/div/div[3]/form/div[4]/div/div[2]/div/table/tbody[last()]/tr/td[5]")).Text;
                Assert.That(lastRowEducationGraduationYear, Is.EqualTo(ExcelLibHelper.ReadData(2, "YearOfGraduation")));
                CommonMethods.test.Log(LogStatus.Pass, "Test Passed, Education Added Successfully");
                SaveScreenShotClass.SaveScreenshot(Driver.driver, "EducationAdded");
            }
            catch (Exception ex)
            {
                CommonMethods.test.Log(LogStatus.Fail, "Test Failed", ex.Message);
            }
        }
        internal void SearchNameSuccesfull()
        {
            //Start the Reports
            CommonMethods.ExtentReports();
            Thread.Sleep(1000);
            CommonMethods.test = CommonMethods.extent.StartTest("Search By Name");

            //click Search user
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='service-search-section']/div[2]/div/section/div/div[1]/div[3]/div[1]/div/div[2]/div[1]/div/span", 10000);
            ClickSearchUser.Click();
            Thread.Sleep(2000);
            CommonMethods.test.Log(LogStatus.Info, "Skill search using name is successfull");
            SaveScreenShotClass.SaveScreenshot(Driver.driver, "SearchByName");
        }
Beispiel #29
0
        internal void FilterShowAll()
        {
            //Start the Reports
            CommonMethods.ExtentReports();
            Thread.Sleep(1000);
            CommonMethods.test = CommonMethods.extent.StartTest("Filter Show All");

            //Search by filter ShowAll
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//*[@id='service-search-section']/div[2]/div/section/div/div[1]/div[5]/button[3]", 10000);
            FilterShowall.Click();
            Thread.Sleep(2000);
            CommonMethods.test.Log(LogStatus.Info, "Skill search using Showall is successfull");
            SaveScreenShotClass.SaveScreenshot(Driver.driver, "FilterShowAll");
        }
        internal void EditDetails()
        {
            //Populate excel data
            ExcelLibHelper.PopulateInCollection(ConstantHelpers.ExcelPath, "ManageListing");
            //Edit title
            WaitHelpers.WaitForElementVisibility(Driver.driver, "Name", "title", 10000);
            Title.Click();
            Title.Clear();
            Title.SendKeys(ExcelLibHelper.ReadData(3, "Title"));

            //Click on save button
            WaitHelpers.WaitForElementVisibility(Driver.driver, "XPath", "//input[@value='Save']", 10000);
            Save.Click();
        }