コード例 #1
0
        public void AddSkill()

        {
            //initialize excel sheet by calling the ExcelLib
            GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "AddShareSkill");

            ShareSkillTab.Click();
            //GlobalDefinitions.wait(10);
            //wait for Title
            GlobalDefinitions.WaitForElement(GlobalDefinitions.driver, By.XPath("//input[@name='title']"), 10);
            AddTitle.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Title"));
            AddDescription.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Description"));
            AddCategory.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Category"));
            AddSubCategory.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Sub Category"));

            AddTags.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Tags"));
            //will perform the enter button's functionality
            enterBtn.SendKeys(Keys.Return).Perform();
            // AddTags.SendKeys(Keys.Enter);
            AddServiceOneOff.Click();
            AddLocationOnline.Click();
            AvailableStartDate.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Start Date"));
            AvailableEndDate.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "End Date"));

            AvailableDays.Click();
            AvailableStartTime.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Start Time"));
            AvailableEndTime.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "End Time"));
            TradeSKillExchange.Click();
            SKillExchangeTag.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Skill Exchange Tage"));
            //will perform the enter button's functionality
            enterBtn.SendKeys(Keys.Return).Perform();
            //Thread.Sleep(2000);
            //find work sample icon and click
            AddWorkSample.Click();
            Process.Start(@"V:\marsframework-master\marsframework-master\Upload.exe");

            // Uploading File path
            //var GetCurrentDirectory = Directory.GetCurrentDirectory();
            //String path = GetCurrentDirectory + @"\MarsFramework\Upload Files\Samplework.txt";
            //AddWorkSample.SendKeys(path);

            //AddWorkSample.SendKeys("file path");
            //GlobalDefinitions.wait(10);
            //Thread.Sleep(5000);
            SelectActive.Click();
            //Thread.Sleep(5000);
            SaveSkill.Click();
        }
コード例 #2
0
        public void EditExistingSkill()
        {
            //initialize excel sheet by calling the ExcelLib

            GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "EditSkill");

            ManageListinTab.Click();
            EditSkillIcon.Click();

            UpdateTitle.Clear();
            UpdateTitle.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Title"));
            AddDescription.Clear();
            AddDescription.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Description"));
            AddTags.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Tags"));
            enterBtn.SendKeys(Keys.Return).Perform();
            AvailableDays.Click();
            AvailableStartTime.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Start Time"));
            AvailableEndTime.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "End Time"));
            SaveSkill.Click();
            //GlobalDefinitions.WaitForElement(GlobalDefinitions.driver, By.XPath("//div[@class='ns-box ns-growl ns-effect-jelly ns-type-success ns-show']/div"), 10);
        }
コード例 #3
0
ファイル: Skill.cs プロジェクト: Lavanya2989/CompPageFactory
        internal void SkillAdd()
        {
            // Populate the excel data
            GlobalDefinitions.ExcelLib.PopulateInCollection(Base.ExcelPath, "ProfilePage");
            GlobalDefinitions.WaitForElement(GlobalDefinitions.driver, By.XPath("//a[@data-tab='second']"));

            //Click Skill tab
            ClickSkilltab.Click();

            //Click Add new
            ClickAddnewSkill.Click();

            //Add Skill
            AddnewSkill.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Skill"));

            //Add Level
            SelectSkillLevel.SendKeys(GlobalDefinitions.ExcelLib.ReadData(2, "Skill Level"));

            //Save Skill
            SaveSkill.Click();
        }