public void A16_Test_Access_Keys_with_Curriculum_34153() { #region Create General Course and Curriculum With Cost and Access keys Enabled CommonSection.CreateLink.GeneralCourse(); _test.Log(Status.Info, "Creating a Paid General Course"); GeneralCoursePage.CreateGeneralCourse(generalcourse + "Curr", "Test General Course"); GeneralCoursePage.setCost("5"); DocumentPage.ClickButton_CheckIn(); _test.Log(Status.Info, "Paid general course created"); CommonSection.Learn.Home(); CommonSection.CreateLink.Curriculam(); _test.Log(Status.Info, "Creating a Paid Curriculum Course with Access Keys"); objCreate.FillCurriculumPage("AK", browserstr); GeneralCoursePage.setCost("5"); _test.Log(Status.Info, "Cost Has Been Set"); BundlesPage.enableAccessKeys(); _test.Log(Status.Info, "Access Keys Enabled"); CurriculumsPage.CurriculumContent.addContentIntoCurriculam(generalcourse + "Curr"); _test.Log(Status.Info, "Adding Paid General Course into Curriculum"); DocumentPage.ClickButton_CheckIn(); #endregion #region Purchase Access Keys for Curriculam ShoppingCarts.purchaseAccessKeys("Curriculam", Variables.curriculumTitle + browserstr + "AK"); ShoppingCarts.completePurchaseProcess(); _test.Log(Status.Info, "Keys has been purchased from shopping cart"); CommonSection.Manage.Training(); CommonSection.Manage.AccessKeys(); AccessKeysPage.searchForContent(Variables.curriculumTitle + browserstr + "AK"); AccessKeysPage.assignKeysToLearner("*****@*****.**"); _test.Log(Status.Info, "Keys has been assigned to learner"); driver.LogoutUser(ObjectRepository.LogoutHoverLink, ObjectRepository.HoverMainLink); #endregion LoginPage.LoginAs("ssuser1").WithPassword("password").Login(); Assert.IsTrue(CurriculumsPage.searchforCurriculam(Variables.curriculumTitle + browserstr + "AK", generalcourse + "Curr")); _test.Log(Status.Info, "General Course Displaying inside Curriculuam, Assertion Pass"); Assert.IsTrue(Driver.Instance.IsElementVisible(By.XPath("//input[@value='Enroll']"))); // TC_10823 = true; _test.Log(Status.Info, "Cost of General Course Override, Assertion Pass"); driver.LogoutUser(ObjectRepository.LogoutHoverLink, ObjectRepository.HoverMainLink); LoginPage.LoginAs("").WithPassword("").Login(); }
//Editing existing certification public void A07_ManageACertification_10879() { CommonSection.CreateLink.Certifications(); // objCreate.FillCertificationPageByExcel(driver); // Assert.IsTrue(Driver.checkTagsonContentCreationPage(true)); objCreate.FillCertificationPage("editcontent"); CommonSection.Manage.Training(); TrainingPage.SearchRecord(Variables.certTitle + "editcontent"); SearchResultsPage.ClickCourseTitle(Variables.certTitle + "editcontent"); CurriculumsPage.Edit_Click(driver); // Assert.IsTrue(Driver.checkTagsonContentCreationPage(true)); GeneralCoursePage.SearchTagForNewContent(tagname); _test.Log(Status.Info, "Searching Tag."); SummaryPage.ClickSavebutton(); // Assert.IsTrue(Driver.checkContentTagsOnDetailsPage()); string s = Driver.GetElement(By.XPath("//strong[contains(.,'" + tagname + "')]")).Text; StringAssert.AreEqualIgnoringCase(tagname, s); _test.Log(Status.Info, "Assertion Pass as Searching for Tag Successfully Done"); TC_10879 = true; }