Beispiel #1
0
        public void DeleteAllScheme(string[] basicDetails, string[] teachingGroup)
        {
            SeleniumHelper.Login(SeleniumHelper.iSIMSUserType.SchoolAdministrator, "Curriculum Structure");
            AutomationSugar.NavigateMenu("Tasks", "School Groups", "Curriculum Structure");
            Wait.WaitForDocumentReady();

            Random rnd          = new Random();
            string displayOrder = rnd.Next(1, 50).ToString();

            var curriculumStructureTriplet = new CurriculumStructureTriplet();

            curriculumStructureTriplet.SearchCriteria.SearchBySchemeName = "Logigear_";
            //curriculumStructureTriplet.SearchCriteria.SearchByAcademicYear = null;
            var searchResultList = curriculumStructureTriplet.SearchCriteria.Search().ToList();

            if (searchResultList.Count > 0)
            {
                foreach (var schemeResult in searchResultList)
                {
                    var searchResult            = curriculumStructureTriplet.SearchCriteria.Search().FirstOrDefault();
                    var CurriculumStructurePage = searchResult.Click <CurriculumStructurePage>();
                    curriculumStructureTriplet.Delete();
                    curriculumStructureTriplet.Refresh();
                }
            }
        }
Beispiel #2
0
        public void DeleteBandScheme(string[] basicDetails, string[] structuralGroup)
        {
            SeleniumHelper.Login(SeleniumHelper.iSIMSUserType.SchoolAdministrator, "Curriculum Structure");
            AutomationSugar.NavigateMenu("Tasks", "School Groups", "Curriculum Structure");
            Wait.WaitForDocumentReady();

            Random rnd          = new Random();
            int    displayOrder = rnd.Next(1, 50);

            var curriculumStructureTriplet = new CurriculumStructureTriplet();

            curriculumStructureTriplet.Create();
            var bandSchemePage = curriculumStructureTriplet.CreateBandSchemePage();

            bandSchemePage.BandSchemeName       = basicDetails[0];
            bandSchemePage.AcademicYearDropDown = basicDetails[1];
            var structuralGroupDialog = bandSchemePage.ClickAddTeachingGroup();

            structuralGroupDialog.ShortName    = structuralGroup[1];
            structuralGroupDialog.DisplayOrder = displayOrder;
            structuralGroupDialog.Save();
            Wait.WaitForDocumentReady();
            var sourceClassDialog = bandSchemePage.ClickAddSourceClass();

            sourceClassDialog.SearchResult[0].ClickByJS();
            sourceClassDialog.AddSelectedClass();
            sourceClassDialog.OkButton();
            curriculumStructureTriplet.Save();
            Assert.AreEqual(false, bandSchemePage.IsSuccessMessageDisplayed(), "Structural Group Record Saved");
            curriculumStructureTriplet.SearchCriteria.SearchBySchemeName = basicDetails[0];
            var searchResult   = curriculumStructureTriplet.SearchCriteria.Search().FirstOrDefault();
            var BandSchemePage = searchResult.Click <BandSchemePage>();

            curriculumStructureTriplet.Delete();
        }
Beispiel #3
0
        public void DeleteAllScheme(string[] basicDetails, string[] structuralGroup)
        {
            SeleniumHelper.Login(SeleniumHelper.iSIMSUserType.SchoolAdministrator, "Curriculum Structure");
            AutomationSugar.NavigateMenu("Tasks", "School Groups", "Curriculum Structure");
            Wait.WaitForDocumentReady();

            var curriculumStructureTriplet = new CurriculumStructureTriplet();

            curriculumStructureTriplet.SearchCriteria.SearchBySchemeName = "Logigear_";
            var searchResultList = curriculumStructureTriplet.SearchCriteria.Search().ToList();

            foreach (var schemeResult in searchResultList)
            {
                var searchResult            = curriculumStructureTriplet.SearchCriteria.Search().FirstOrDefault();
                var CurriculumStructurePage = searchResult.Click <CurriculumStructurePage>();
                curriculumStructureTriplet.Delete();
                curriculumStructureTriplet.Refresh();
            }
        }