Support for Microsoft CodedUI

Sam Thwaites's Avatar

Sam Thwaites

13 Sep, 2014 01:32 AM


Whilst trying to execute my tests using Microsoft CodedUI I receive the errors below.

From my understanding of the error and working with CodedUI over the years, if the build process is being run by a service, then that service must be able to interact with the desktop.

I'm pretty certain AppVeyor currently doesn't support Microsoft CodedUI, however is there any chance in the future you will?

Error Message:

Error calling Initialization method for test class <BLAH>: Microsoft.VisualStudio.TestTools.UITest.Extension.UITestException: To run tests that interact with the desktop, you must set up the test agent to run as an interactive process. For more information, see "How to: Set Up Your Test Agent to Run Tests That Interact with the Desktop" (
If you are running the tests as part of your team build, you must also set up the build agent to run as an interactive process. For more information, see "How to: Configure and Run Scheduled Tests After Building Your Application" (
Stack Trace:
    at Microsoft.VisualStudio.TestTools.UITesting.Playback.Initialize()
   at Microsoft.VisualStudio.TestTools.UITesting.CodedUITestExtensionExecution.BeforeTestInitialize(Object sender, BeforeTestInitializeEventArgs e)
   at Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestExecution.RaiseBeforeTestInitialize(BeforeTestInitializeEventArgs args)
   at Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestExecuter.RunInitializeMethod()
  1. Support Staff 1 Posted by Feodor Fitsner on 14 Sep, 2014 12:10 AM

    Feodor Fitsner's Avatar

    Will take a look!


  2. Support Staff 2 Posted by Feodor Fitsner on 16 Sep, 2014 03:11 AM

    Feodor Fitsner's Avatar

    OK, I see that the main issue here is running AppVeyor build agent in interactive mode, i.e. as process, not as a service.

    We are working on an update to build worker (and VM image) to make it work as a process, so in a week-two you'll be able to give it a try.

  3. Support Staff 3 Posted by Feodor Fitsner on 29 Oct, 2014 06:59 PM

    Feodor Fitsner's Avatar

    Hi Sam,

    It took a little bit longer, but we got a new environment with build workers running interactively. Would you like to give Coded UI tests another try?

  4. 4 Posted by Daniel Cazzulin... on 15 Jan, 2016 05:40 PM

    Daniel Cazzulino's Avatar

    I'm interested in this too. How do we pick an environment which runs the workers interactively? Is it enabled automatically by default?

  5. Support Staff 5 Posted by Feodor Fitsner on 15 Jan, 2016 05:42 PM

    Feodor Fitsner's Avatar

    Hi Daniel,

    It should be supported. What's your AppVeyor account name?

  6. Ilya Finkelshteyn closed this discussion on 25 Aug, 2018 02:03 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac