テスト環境 - C#.netのSelenium Webドライバでテストを書くことに取り組んでいます。それらをNUnit経由で実行します。 ベースURL - http://localhost/OnlineTest/login.aspx 内部には、グリッドがあるiframeがあります ここに自動化したいものがあります。WebDriverの問題 - 別のウィンドウにアクセスできません。エラー - そのようなウィンドウは見つかりませんでした。 NoSuchWindowException
• Go to the Grid
• Click on an image.
• It opens new window(like a pop up).
• Go to that window .
• Verify its text & click Close button.
コードで別のウィンドウに移動する方法が見つかりません。
これは私がしようとしたものです - IWebElement要素= driver.SwitchTo()ウィンドウ( "ViewQuestionPreview.aspx QsnId = Qsn16?")FindElement(By.Id( "btnClose"));。。
私は
- "/ViewQuestionPreview.aspx?QsnId=Qsn16"
- のような異なるcombinitionsにURLをも変更しました "のhttp:?//localhost/OnlineTest/ViewQuestionPreview.aspx QsnId = Qsn16"
- "/OnlineTest/ViewQuestionPreview.aspx?QsnId=Qsn16"
"OnlineTest/ViewQuestionPreview.aspx?QsnId = Qsn16"
エラー - このようなウィンドウは見つかりませんでした。
NoSuchWindowExceptionを助けることができる誰かの感謝します。
タヒル