I have a coded UI Test that was working fine running locally in debug mode, and randomly just stopped. It still works on other dev pc's but no longer on my PC.
I don't appear to have received any Windows updates or VS updates from when it worked and didn't . What its now doing is clicking the incorrect menu item or not finding a button to click even though its present. The mappings are correct and do work on other machines and its not a timing issue as valid waits are in place and as i said it is working fine on other machines.
Visual Studio Version 15.8.6 Enterprise 2017
Internet Explorer 11.0.90
The exception on the output where it doesn't work seems to indicate an exception with zoom, but the test shouldn't be trying to zoom
IEDOM : ZoomPercentage: Exception when trying to get zoom
The debug output from when it works is as follows
W, 2964, 13, 2018/10/11, 08:48:22.121, 672892725381, QTAgent32_40.exe, Playback - {8} [SUCCESS] EnsureVisible - "[Web]ControlType='ComboBox' && TagName='SELECT' && Id='ctl00_ContentPlaceHolder1_ddlStore' && Name='ctl00$ContentPlaceHolder1$ddlStore' && FilterCondition(LabeledBy='', Size='0', Title='', ItemCount='545', Class='form-control05', ControlDefinition='name="ctl00$ContentPlaceHolder1$ddlStore', TagInstance='1')" < Element is clickable > W, 2964, 13, 2018/10/11, 08:48:27.489, 672946394526, QTAgent32_40.exe, IEDOMPlugin: Cannot add property Src as the validity check failed. Disable ApplySmartConfiguration flag to bypass validity checks. W, 2964, 13, 2018/10/11, 08:48:27.664, 672948150154, QTAgent32_40.exe, Playback - {9} [SUCCESS] MouseButtonClick - "[Web]ControlType='Button' && TagName='INPUT' && Id='ctl00_ContentPlaceHolder1_btnNext' && Name='ctl00$ContentPlaceHolder1$btnNext' && FilterCondition(DisplayText='Next', Type='submit', Title='', Class='btn btn-success m-r-5 m-b-5 btn-xs m-r-5', ControlDefinition='name="ctl00$ContentPlaceHolder1$btnNext"', TagInstance='8')" The thread 0x1ce4 has exited with code 0 (0x0). E, 2964, 13, 2018/10/11, 08:48:37.846, 673049974977, QTAgent32_40.exe, Exception: System.Runtime.InteropServices.COMException Message: Error HRESULT E_FAIL has been returned from a call to a COM component. Stack Trace: at Accessibility.IAccessible.get_accRole(Object varChild) at Microsoft.VisualStudio.TestTools.UITest.Extension.Msaa.AccWrapper.get_RoleInt() BaseExceptionMessage: Error HRESULT E_FAIL has been returned from a call to a COM component.
E, 2964, 13, 2018/10/11, 08:48:37.853, 673050042429, QTAgent32_40.exe, Exception: System.Runtime.InteropServices.COMException Message: Error HRESULT E_FAIL has been returned from a call to a COM component. Stack Trace: at Accessibility.IAccessible.get_accState(Object varChild) at Microsoft.VisualStudio.TestTools.UITest.Extension.Msaa.AccWrapper.get_State() BaseExceptionMessage: Error HRESULT E_FAIL has been returned from a call to a COM component.
E, 2964, 13, 2018/10/11, 08:48:37.857, 673050081579, QTAgent32_40.exe, Exception: System.Runtime.InteropServices.COMException Message: Error HRESULT E_FAIL has been returned from a call to a COM component. Stack Trace: at Accessibility.IAccessible.get_accRole(Object varChild) at Microsoft.VisualStudio.TestTools.UITest.Extension.Msaa.AccWrapper.get_RoleInt() BaseExceptionMessage: Error HRESULT E_FAIL has been returned from a call to a COM component.
E, 2964, 13, 2018/10/11, 08:48:37.860, 673050111131, QTAgent32_40.exe, Exception: System.Runtime.InteropServices.COMException Message: Error HRESULT E_FAIL has been returned from a call to a COM component. Stack Trace: at Accessibility.IAccessible.get_accRole(Object varChild) at Microsoft.VisualStudio.TestTools.UITest.Extension.Msaa.AccWrapper.get_RoleInt() BaseExceptionMessage: Error HRESULT E_FAIL has been returned from a call to a COM component.
W, 2964, 13, 2018/10/11, 08:48:38.247, 673053976659, QTAgent32_40.exe, Playback - {10} [SUCCESS] MouseButtonClick - "[Web]ControlType='Hyperlink' && TagName='A' && Id='' && Name='' && Target='' && InnerText='Clubs' && FilterCondition(AbsolutePath='/test.aspx', Title='', 'test.aspx', Class='', ControlDefinition='href="test', TagInstance='5')" The thread 0x4b50 has exited with code 0 (0x0). E, 2964, 13, 2018/10/11, 08:48:46.403, 673135533276, QTAgent32_40.exe, Exception: System.Runtime.InteropServices.COMException Message: Error HRESULT E_FAIL has been returned from a call to a COM component. Stack Trace: at Accessibility.IAccessible.get_accRole(Object varChild) at Microsoft.VisualStudio.TestTools.UITest.Extension.Msaa.AccWrapper.get_RoleInt() BaseExceptionMessage: Error HRESULT E_FAIL has been returned from a call to a COM component.
E, 2964, 13, 2018/10/11, 08:48:46.407, 673135575029, QTAgent32_40.exe, Exception: System.Runtime.InteropServices.COMException Message: Error HRESULT E_FAIL has been returned from a call to a COM component. Stack Trace: at Accessibility.IAccessible.get_accState(Object varChild) at Microsoft.VisualStudio.TestTools.UITest.Extension.Msaa.AccWrapper.get_State() BaseExceptionMessage: Error HRESULT E_FAIL has been returned from a call to a COM component.
E, 2964, 13, 2018/10/11, 08:48:46.411, 673135615631, QTAgent32_40.exe, Exception: System.Runtime.InteropServices.COMException Message: Error HRESULT E_FAIL has been returned from a call to a COM component. Stack Trace: at Accessibility.IAccessible.get_accRole(Object varChild) at Microsoft.VisualStudio.TestTools.UITest.Extension.Msaa.AccWrapper.get_RoleInt() BaseExceptionMessage: Error HRESULT E_FAIL has been returned from a call to a COM component.
E, 2964, 13, 2018/10/11, 08:48:46.414, 673135644030, QTAgent32_40.exe, Exception: System.Runtime.InteropServices.COMException Message: Error HRESULT E_FAIL has been returned from a call to a COM component. Stack Trace: at Accessibility.IAccessible.get_accRole(Object varChild) at Microsoft.VisualStudio.TestTools.UITest.Extension.Msaa.AccWrapper.get_RoleInt() BaseExceptionMessage: Error HRESULT E_FAIL has been returned from a call to a COM component.
W, 2964, 13, 2018/10/11, 08:48:46.524, 673136740553, QTAgent32_40.exe, IEDOMPlugin: Cannot add property Src as the validity check failed. Disable ApplySmartConfiguration flag to bypass validity checks. W, 2964, 13, 2018/10/11, 08:48:46.712, 673138627073, QTAgent32_40.exe, Playback - {11} [SUCCESS] MouseButtonClick - "[Web]ControlType='Button' && TagName='INPUT' && Id='ctl00_ContentPlaceHolder1_btnNewClub' && Name='ctl00$ContentPlaceHolder1$btnNewClub' && FilterCondition(DisplayText='Add Club', Type='submit', Title='', Class='btn btn-success m-r-5 m-b-5 btn-xs m-r-5', ControlDefinition='name="ctl00$ContentPlaceHolder1$btnNewCl', TagInstance='8')"
And the output from when it doesnt is
W, 10996, 13, 2018/10/11, 09:09:59.532, 685866771965, QTAgent32_40.exe, Playback - {8} [SUCCESS] EnsureVisible - "[Web]ControlType='ComboBox' && TagName='SELECT' && Id='ctl00_ContentPlaceHolder1_ddlStore' && Name='ctl00$ContentPlaceHolder1$ddlStore' && FilterCondition(LabeledBy='', Size='0', Title='', ItemCount='545', Class='form-control05', ControlDefinition='name="ctl00$ContentPlaceHolder1$ddlStore', TagInstance='1')" < Element is clickable > W, 10996, 13, 2018/10/11, 09:10:04.900, 685920458422, QTAgent32_40.exe, IEDOMPlugin: Cannot add property Src as the validity check failed. Disable ApplySmartConfiguration flag to bypass validity checks. W, 10996, 13, 2018/10/11, 09:10:05.075, 685922211403, QTAgent32_40.exe, Playback - {9} [SUCCESS] MouseButtonClick - "[Web]ControlType='Button' && TagName='INPUT' && Id='ctl00_ContentPlaceHolder1_btnNext' && Name='ctl00$ContentPlaceHolder1$btnNext' && FilterCondition(DisplayText='Next', Type='submit', Title='', Class='btn btn-success m-r-5 m-b-5 btn-xs m-r-5', ControlDefinition='name="ctl00$ContentPlaceHolder1$btnNext"', TagInstance='8')" W, 10996, 13, 2018/10/11, 09:10:15.374, 686025189722, QTAgent32_40.exe, IEDOM : ZoomPercentage: Exception when trying to get zoom: System.Runtime.InteropServices.InvalidComObjectException: COM object that has been separated from its underlying RCW cannot be used. at System.StubHelpers.InterfaceMarshaler.ConvertToNative(Object objSrc, IntPtr itfMT, IntPtr classMT, Int32 flags) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.Communication.Interop.IECommunicatorClass.PageZoom(Object punkWebBrowser) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.DocumentManager.get_ZoomPercentage() W, 10996, 13, 2018/10/11, 09:10:15.419, 686025645733, QTAgent32_40.exe, IEDOM : ZoomPercentage: Exception when trying to get zoom: System.Runtime.InteropServices.InvalidComObjectException: COM object that has been separated from its underlying RCW cannot be used. at System.StubHelpers.InterfaceMarshaler.ConvertToNative(Object objSrc, IntPtr itfMT, IntPtr classMT, Int32 flags) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.Communication.Interop.IECommunicatorClass.PageZoom(Object punkWebBrowser) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.DocumentManager.get_ZoomPercentage() W, 10996, 13, 2018/10/11, 09:10:15.544, 686026897425, QTAgent32_40.exe, IEDOM : ZoomPercentage: Exception when trying to get zoom: System.Runtime.InteropServices.InvalidComObjectException: COM object that has been separated from its underlying RCW cannot be used. at System.StubHelpers.InterfaceMarshaler.ConvertToNative(Object objSrc, IntPtr itfMT, IntPtr classMT, Int32 flags) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.Communication.Interop.IECommunicatorClass.PageZoom(Object punkWebBrowser) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.DocumentManager.get_ZoomPercentage() W, 10996, 13, 2018/10/11, 09:10:15.546, 686026913893, QTAgent32_40.exe, IEDOM : ZoomPercentage: Exception when trying to get zoom: System.Runtime.InteropServices.InvalidComObjectException: COM object that has been separated from its underlying RCW cannot be used. at System.StubHelpers.InterfaceMarshaler.ConvertToNative(Object objSrc, IntPtr itfMT, IntPtr classMT, Int32 flags) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.Communication.Interop.IECommunicatorClass.PageZoom(Object punkWebBrowser) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.DocumentManager.get_ZoomPercentage() W, 10996, 13, 2018/10/11, 09:10:15.566, 686027113668, QTAgent32_40.exe, IEDOM : ZoomPercentage: Exception when trying to get zoom: System.Runtime.InteropServices.InvalidComObjectException: COM object that has been separated from its underlying RCW cannot be used. at System.StubHelpers.InterfaceMarshaler.ConvertToNative(Object objSrc, IntPtr itfMT, IntPtr classMT, Int32 flags) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.Communication.Interop.IECommunicatorClass.PageZoom(Object punkWebBrowser) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.DocumentManager.get_ZoomPercentage() W, 10996, 13, 2018/10/11, 09:10:15.576, 686027216184, QTAgent32_40.exe, IEDOM : ZoomPercentage: Exception when trying to get zoom: System.Runtime.InteropServices.InvalidComObjectException: COM object that has been separated from its underlying RCW cannot be used. at System.StubHelpers.InterfaceMarshaler.ConvertToNative(Object objSrc, IntPtr itfMT, IntPtr classMT, Int32 flags) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.Communication.Interop.IECommunicatorClass.PageZoom(Object punkWebBrowser) at Microsoft.VisualStudio.TestTools.UITest.Extension.IE.DocumentManager.get_ZoomPercentage() W, 10996, 13, 2018/10/11, 09:10:15.725, 686028707079, QTAgent32_40.exe, Playback - {10} [SUCCESS] MouseButtonClick - "[Web]ControlType='Hyperlink' && TagName='A' && Id='' && Name='' && Target='' && InnerText='Store Clubs' && FilterCondition(AbsolutePath='/test.aspx', Title='', Href='test.aspx', Class='', ControlDefinition='href="test', TagInstance='5')"