public void SeleniumShowChromeRightClickError() { var selenium = new Selenium(); // Chrome cannot interact with context menus. Workaround is using native sendkeys, but we don't want to go there. // This test tries to select all in the context meny and then press delete. It just presses delete instead, so the // field doesn't get empty. If this test would fail, right click would work selenium.SetBrowser("chrome"); selenium.SetTimeoutSeconds(20); const string textboxLocator = "id:text1"; Assert.IsTrue(selenium.Open(EndToEndTest.CreateTestPageUri()), "Open page"); Assert.IsTrue(selenium.WaitUntilTitleMatches("Selenium Fixture Test Page")); Assert.IsTrue(selenium.RightClickElement(textboxLocator), "Show context menu"); Selenium.WaitSeconds(0.2); // allow dropdown to expand const string selectAllInContextMenuSequence = "{DOWN}a"; selenium.SendKeysToElement(new KeyConverter(selectAllInContextMenuSequence).ToSeleniumFormat, textboxLocator); selenium.SendKeysToElement("{DELETE}", textboxLocator); Assert.IsFalse(string.IsNullOrEmpty(selenium.AttributeOfElement("value", textboxLocator)), "text 1 is empty"); selenium.Close(); }