ExecuteAutomation

Working with Menu items with Coypu for Selenium C#

In this post we will be working with Menu items and identifying if the menu items really exist in the page menu bar using Coypu for Selenium C# The menu bar and item we are going to work with is going to be this                 Here is the complete video of the above discussion Here is the complete code
var sessionConfiguration = new SessionConfiguration()
            {
                Browser = Browser.Firefox,
                AppHost = "executeautomation.com"
            };

            var browser = new BrowserSession(sessionConfiguration);
            browser.Visit("/demosite/Login.html");
            //userName
            browser.FillIn("UserName").With("admin");
            //Password
            browser.FillIn("Password").With("password");
            //Click button
            browser.ClickButton("Login");

            browser.FindId("Automation Tools").Hover();

            Assert.That(browser, Shows.Css("ul > li > a > span", text: "Seleniums"));
            Assert.That(browser, Shows.Css("ul > li > a > span", text: "BDD"));
Well, I hope that answers everyone questions!!! Thanks for reading the post and share your opinions and comments. Thanks, Karthik KK