Coded UI error: The following element is not longer availabe

后端 未结 7 853
清歌不尽
清歌不尽 2021-01-14 15:44

I recorded some test cases with CUIT in VS2010. Everything worked fine the day before. So, today I run again, all the test failed, with the warning: The following element is

7条回答
  •  被撕碎了的回忆
    2021-01-14 16:21

    One of the biggest problem while analyzing the Coded UI test failures is that the error stack trace indicates the line of code which might be completely unrelated to the actual cause of failure.

    I would suggest you to enable HTML logging in your tests - this will display step by step details of how Coded UI tried to execute the tests - with screenshots of your application. It will also highlight the control in red which Coded UI is trying to search/operate upon.This is very beneficial in troubleshooting the actual cause of test failures.

    To enable tracing you can just add the below code to your app.config file --

提交回复
热议问题