In my application flow, a new tab is opened in Google Chrome after clicking a button, I want to fire more click events and test the application in this new tab but the click events are not getting fired.
Below is what I have tried so far:
IBrowser myNewTab = BrowserFactory.Attach(new BrowserDescription
{
Title = "MyNewTabTitle"
});
IWebElement newTabObject = myNewTab.Describe<IWebElement>(new WebElementDescription
{
XPath = "XPath_Of_My_Control_On_New_Tab"
});
newTabObject.Click();
But after executing this I am still getting the error as, threw exception:
HP.LFT.SDK.ReplayObjectNotFoundException: attachApplication
I have also tried to apply different properties for newTabObject
like Title
, Url
.