public void A04_Test_AccessKeys_Accordian_For_ClassroomCourse_35813() { #region Create Classroom Course with Cost and Access Keys CommonSection.CreateLink.ClassroomCourse(); _test.Log(Status.Info, "Opened Create Classroom Course Page"); classroomcourse.populateClassroomform(ExtractDataExcel.MasterDic_classrommcourse["Title"] + "Create" + browserstr, ExtractDataExcel.MasterDic_classrommcourse["Desc"]); _test.Log(Status.Info, "Filled all required information and submit the classroom creation page"); classroomcourse.buttonsaveclick(); _test.Log(Status.Pass, "Verify Classroom Course saved"); Assert.IsTrue(Driver.Instance.IsElementVisible(By.XPath("//a[@id='MainContent_MainContent_ucAccessCodes_lnkEdit']"))); _test.Log(Status.Pass, "Access Keys According displaying for classroom course"); Assert.IsTrue(ClassroomCoursePage.enableAccessKeys()); _test.Log(Status.Info, "Access Keys Enabled for classroom course"); GeneralCoursePage.setCost("5"); _test.Log(Status.Info, "Cost Has Been Set"); #endregion ManageClassroomCoursePage.Clicktab("Sections"); ManageClassroomCoursePage.CreateSection.ClickAddaNewSection(); ManageClassroomCoursePage.CreateSection.TitleAs("Section1"); ManageClassroomCoursePage.CreateSection.SectionMaxCapacity("1"); _test.Log(Status.Pass, "Enter Section Title and Capacity"); ManageClassroomCoursePage.SelectWaitListasYes(); Assert.IsTrue(ManageClassroomCoursePage.setAvailable_for_Purchase()); _test.Log(Status.Pass, "Availability for purchase detail for access keys has been set"); ManageClassroomCoursePage.CreateSection.Create(); _test.Log(Status.Pass, "New Section Created"); Assert.IsTrue(ClassroomCoursePage.GetNewCreatedSectionLink("Section1")); _test.Log(Status.Pass, "Classroom Course Section Created With Access Keys Enabled"); }
public void A10_Test_AccessKeys_Accordian_For_AICC_35819() { #region Create AICC Course Document documentpage = new Document(driver); string expectedresult = "Summary"; string expectedresult1 = "The course was created."; AICC aicccourse = new AICC(driver); Scorm12 CreateScorm = new Scorm12(driver); CommonSection.CreateLink.AICC(); driver.navigateAICCfile("Data\\mv_mvet_a03_it_enus.au", By.Id("ctl00_MainContent_UC1_rau_aufile0")); driver.navigateAICCfile("Data\\mv_mvet_a03_it_enus.crs", By.Id("ctl00_MainContent_UC1_rau_crsfile0")); driver.navigateAICCfile("Data\\mv_mvet_a03_it_enus.cst", By.Id("ctl00_MainContent_UC1_rau_cstfile0")); driver.navigateAICCfile("Data\\mv_mvet_a03_it_enus.des", By.Id("ctl00_MainContent_UC1_rau_desfile0")); CreateScorm.buttoncreateclick(driver, true); string actualresult = driver.gettextofelement(By.XPath("//h1[contains(.,'Summary')]")); Assert.IsTrue(driver.Compareregexstring(expectedresult, actualresult)); driver.WaitForElement(By.XPath("//*[contains(@class,'alert alert-success')]")); Assert.IsTrue(driver.Compareregexstring(expectedresult1, driver.gettextofelement(By.XPath("//*[contains(@class,'alert alert-success')]")))); aicccourse.populatesummaryform(driver, browserstr); Assert.IsTrue(CreateScorm.buttonsaveclick(driver)); #endregion GeneralCoursePage.setCost("5"); _test.Log(Status.Info, "Cost Has Been Set"); DocumentPage.ClickButton_CheckOut(); Assert.IsTrue(ClassroomCoursePage.enableAccessKeys()); _test.Log(Status.Info, "Access Keys Accordian Has been verfiied for AICC Course"); }
public void A10_Test_AccessKeys_Accordian_For_Scorm_35818() { CommonSection.Learn.Home(); CommonSection.CreteNewScorm(scormtitle + "AK"); _test.Log(Status.Info, "New Scorm Course Created"); GeneralCoursePage.setCost("5"); _test.Log(Status.Info, "Cost Has Been Set"); Assert.IsTrue(ClassroomCoursePage.enableAccessKeys()); _test.Log(Status.Info, "Access Keys Accordian Has been verfiied for Scorm Course"); }
public void A09_Test_AccessKeys_Accordian_For_GeneralCourse_35817() { CommonSection.Learn.Home(); CommonSection.CreateLink.GeneralCourse(); _test.Log(Status.Info, "Creating a Paid General Course"); GeneralCoursePage.CreateGeneralCourse(generalcourse + "AK", "Test General Course"); GeneralCoursePage.setCost("5"); _test.Log(Status.Info, "Cost Has Been Set"); Assert.IsTrue(ClassroomCoursePage.enableAccessKeys()); _test.Log(Status.Info, "Access Keys Accordian Has been verfiied for General Course"); }
public void A11_Access_Key_Expire_When_User_Completed_the_Content_Bundle_34189() { #region Create General Course and Bundle With Cost and Access keys Enabled CommonSection.CreateLink.GeneralCourse(); _test.Log(Status.Info, "Creating a Paid General Course"); GeneralCoursePage.CreateGeneralCourse(generalcourse + "TC34189", "Test General Course"); GeneralCoursePage.setCost("5"); DocumentPage.ClickButton_CheckIn(); _test.Log(Status.Info, "Paid general course created"); CommonSection.Learn.Home(); CommonSection.CreateLink.Bundle(); _test.Log(Status.Info, "Creating a Paid Bundle Course with Access Keys"); objCreate.FillBundlePage(browserstr + "TC34189"); GeneralCoursePage.setCost("5"); _test.Log(Status.Info, "Cost Has Been Set"); BundlesPage.enableAccessKeys(); _test.Log(Status.Info, "Access Keys Enabled"); BundlesPage.addContentIntoBundle(generalcourse + "TC34189"); _test.Log(Status.Info, "Adding Paid General Course into Bundle"); DocumentPage.ClickButton_CheckIn(); #endregion #region Purchase Access Keys for Bundle ShoppingCarts.purchaseAccessKeys("Bundle", Variables.bundleTitle + browserstr + "TC34189"); ShoppingCarts.completePurchaseProcess(); _test.Log(Status.Info, "Keys has been purchased from shopping cart"); CommonSection.Manage.Training(); CommonSection.Manage.AccessKeys(); AccessKeysPage.searchForContent(Variables.bundleTitle + browserstr + "TC34189"); 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(BundlesPage.searchforBundle(Variables.bundleTitle + browserstr + "TC34189", generalcourse + "TC34189")); _test.Log(Status.Info, "General Course Displaying inside Bundle, Assertion Pass"); Assert.IsTrue(Driver.Instance.IsElementVisible(By.XPath("//input[@value='Enroll']"))); _test.Log(Status.Info, "Cost of General Course Override, Assertion Pass"); GeneralCoursePage.completeGeneralCourse(); BundlesPage.simplysearchforBundle(Variables.bundleTitle + browserstr + "TC34189"); Assert.IsTrue(Driver.Instance.IsElementVisible(By.XPath("//p[contains(.,'You have already completed this item. You must use another access key to begin a new attempt.')]"))); driver.LogoutUser(ObjectRepository.LogoutHoverLink, ObjectRepository.HoverMainLink); LoginPage.LoginAs("").WithPassword("").Login(); }
public void A05_Test_AccessKeys_Accordian_For_Bundle_35814() { #region Create General Course and Bundle With Cost and Access keys Enabled CommonSection.CreateLink.GeneralCourse(); _test.Log(Status.Info, "Creating a Paid General Course"); GeneralCoursePage.CreateGeneralCourse(generalcourse, "Test General Course"); GeneralCoursePage.setCost("5"); DocumentPage.ClickButton_CheckIn(); _test.Log(Status.Info, "Paid general course created"); CommonSection.Learn.Home(); CommonSection.CreateLink.Bundle(); _test.Log(Status.Info, "Creating a Paid Bundle Course with Access Keys"); objCreate.FillBundlePage(browserstr); GeneralCoursePage.setCost("5"); _test.Log(Status.Info, "Cost Has Been Set"); Assert.IsTrue(ClassroomCoursePage.enableAccessKeys()); _test.Log(Status.Info, "Access Keys Accordian Has been verfiied for Bundle Course"); #endregion }
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(); }
public void A16_Batch_Enroll_and_MarkComplete_User_into_Online_Course_with_Cost_34154() { #region Create General Course with Cost CommonSection.CreateLink.GeneralCourse(); _test.Log(Status.Info, "Creating a Paid General Course"); GeneralCoursePage.CreateGeneralCourse(generalcourse + "TC34154", "Test General Course"); GeneralCoursePage.setCost("5"); DocumentPage.ClickButton_CheckIn(); _test.Log(Status.Info, "Paid general course created"); #endregion CommonSection.Manage.Training(); _test.Log(Status.Info, "Goto Training Page"); CommonSection.Manage.TrainingPage.click_BatchEnrollment_OnlineCourse(); _test.Log(Status.Info, "Click on Batch enroll online course link"); CommonSection.Manage.TrainingPage.searchFor_OnlineContent(generalcourse + "TC34154"); _test.Log(Status.Info, "Search for online course"); CommonSection.Manage.TrainingPage.click_EnrollUserButton(); _test.Log(Status.Info, "Click enroll user button"); Assert.IsTrue(Driver.Instance.isPresent(By.XPath("//div[@aria-disabled='true']"))); _test.Log(Status.Pass, "Batch Enroll and MarkComplete User into Online Course with Cost"); // CommonSection.Manage.TrainingPage.searchFor_UsersToEnroll(""); // CommonSection.Manage.TrainingPage.BatchEnroll_OnlineCourse(); // In Progress // xpath = //label[@id='lblMarkComplete'] }
public void P20_1_A01_User_Can_See_Overview_Tab_of_CurriculumDetailPage_26367() { #region Create a Curriculum and Add Promotional Video CommonSection.CreteNewCurriculumn(curriculamtitle + "_TC26367"); _test.Log(Status.Info, "Create A new Curriculum"); ContentDetailsPage.Accordians.PromotionalVideo.Click_Edit(); _test.Log(Status.Info, "Click Promotional Video Edit button"); PromotionalVideoPage.AddNewURL(PromoURL); ////www.youtube.com/embed/Fc1P-AEaEp8 _test.Log(Status.Info, "Add a URl"); PromotionalVideoPage.Click_SaveButton(); _test.Log(Status.Info, "Click Save button"); Assert.IsTrue(Driver.comparePartialString("The changes were saved.", PromotionalVideoPage.getSuccessfulmessage())); _test.Log(Status.Info, "Verify Successful message"); PromotionalVideoPage.Click_BackButton(); _test.Log(Status.Info, "Click on Course title bread crumb"); #endregion #region Add Cost GeneralCoursePage.setCost("2"); #endregion #region Add Prerequisite ContentDetailsPage.Accordians.ClickEdit_Prerequisites(); _test.Log(Status.Info, "Click on Prerequisities Accordian Edit button"); Assert.IsTrue(PrerequisitesPage.isSearchFiledsdisplay()); _test.Log(Status.Pass, "Verify Search fields are display in Prerequisites page"); PrerequisitesPage.ClickAddPrerequisites(); _test.Log(Status.Info, "Click on ADD Prerequisities Button"); Assert.IsTrue(AddPrerequisitesPage.IsSearchfieldsDisplayed()); _test.Log(Status.Info, "Verify Search for, Search Type, Type, User Search, Add button, Back button display"); AddPrerequisitesPage.SearchFor(""); _test.Log(Status.Info, "Click Search Button, Select One record and click add button"); Assert.IsTrue(PrerequisitesPage.isPrerequisitesadded()); _test.Log(Status.Pass, "Verify Prerequisites are added to Curriculumn"); AddPrerequisitesPage.ClickBackButton(); Assert.IsTrue(ContentDetailsPage.Accordians.VerifyanyPrerequisitesPresent()); _test.Log(Status.Info, "Verify any Prerequisities content display in Accordian"); #endregion #region Add Equivalancies ContentDetailsPage.Accordians.ClickEdit_Equivalencies(); _test.Log(Status.Info, "Click on Prerequisities Accordian Edit button"); Assert.IsTrue(EquivalenciesPage.isSearchFiledsdisplay()); _test.Log(Status.Pass, "Verify Search fields are display in Equivalencies page"); EquivalenciesPage.ClickAddEquivalencies(); _test.Log(Status.Info, "Click on ADD Equivalencies Button"); Assert.IsTrue(AddEquivalenciesPage.IsSearchfieldsDisplayed()); _test.Log(Status.Info, "Verify Search for, Search Type, Type, User Search, Add button, Back button display"); AddEquivalenciesPage.SearchFor("").ClickAddbutton(); _test.Log(Status.Info, "Click Search Button, Select One record and click add button"); Assert.IsTrue(EquivalenciesPage.isEquivalenciesadded()); _test.Log(Status.Pass, "Verify Equivalencies are added to Curriculumn"); #endregion GeneralCoursePage.ClickCheckIn(); CommonSection.SearchCatalog(curriculamtitle + "_TC26367"); _test.Log(Status.Info, "Enter curriculum title in global search box"); SearchResultsPage.ClickCourseTitle(curriculamtitle + "_TC26367"); _test.Log(Status.Info, "Click on search result from catalog"); Assert.IsTrue(ContentDetailsPage.VerifyCurriculumDetailPage(curriculamtitle + "_TC26367")); _test.Log(Status.Info, "Assertion Pass as per Curriculum Detail Page New UI"); TC26963 = true; TC27167 = true; }