In Internet Explorer (especially IE11) with UAC and protected mode enabled, when navigating between URL in different security zones, IE replaces the tab process and the browser test object is not always aware of this so it will not communicate with the new process.
Although spying on the browser works fine.
The most common cases are:
- After launching a browser using BrowserFactory.Launch successfully, the Browser.Navigate method fails or no object is identified in the home page
- After a call to Browser.Navigate method, no object is identified in the navigated page.
- After an operation in the AUT (application under test) that caused the browser to navigate to a new page, no object is identified in the navigated page.
There are multiple possible solutions to this issue:
- Make sure that all the web sites that are in the test are in the same security zone. This includes the home address and about:blank.
To change a site security zone, open internet Options -> Security tab
The zone for the current site is highlighted.
Click sites and add sites as needed.
- Disable Protected Mode for all security zones or enable Protected Mode for all sucurity zones.
- Disable UAC on the machine. This will disable protected mode.
- Use BrowserFactory.Attach to get a new browser test object that works with the new tab process.