私はセレンを使用していくつかのテストを行いました。私はビジュアルスタジオ2015で私のソリューションを作成し、すべてのテストは正常に実行されますが、ビジュアルスタジオ2017でテストを実行すると、すべてのテストが右クリックする必要があるときとは別に機能します。コンテキストクリック(右クリック)ビジュアルスタジオが動作しません2017
は、私が2017
は、私は私がしようとすると右の私が要素の上に左クリックすることができますクリックする前に、要素が行にしかしnullであることを言ってランタイムエラーを取得し、これはVisual Studioでのみ起こっている理由はわからないんだけど私は要素がnullではないことを知っています。私はこの問題を考え出し
var webDriverWait = new WebDriverWait(session, TimeSpan.FromSeconds(10));
Actions action = new Actions(session);
CommonMethods.switchWindows(session);
CommonMethods.keyCheck(session);
Thread.Sleep(2000);
webDriverWait.Until(ExpectedConditions.ElementToBeClickable(session.FindElementByName($"{fileName} - PowerPoint"))).Click();
Thread.Sleep(2000);
webDriverWait.Until(ExpectedConditions.ElementToBeClickable(session.FindElementByName("Create"))).Click();
webDriverWait.Until(ExpectedConditions.ElementToBeClickable(session.FindElementByName("View Links"))).Click();
CommonMethods.IsElementDisplayed(session, new StackTrace(true).GetFrame(0).GetFileLineNumber(), new StackTrace(true).GetFrame(0).GetMethod(), "CreateErrorIcon", "Error appeard when selecting the View Links button");
webDriverWait.Until(ExpectedConditions.ElementToBeClickable(session.FindElementByName("Create"))).Click();
var e =webDriverWait.Until(ExpectedConditions.ElementToBeClickable(session.FindElementByName(SlideNumber)));
e.Click();
action.ContextClick(e).Perform();
webDriverWait.Until(ExpectedConditions.ElementToBeClickable(session.FindElementByName(element))).Click();
keyCheck(session);
完全な例外はポストできますか? – Guy