Step 1: install the adapter
In the link for installing the adapter you provided, the VSIX project is created. The VSIX project has an option (on the VSIX tab) for automatically deploying the adapter in VS Experimental hive on build.
If you are using vstest.console.exe , you do not need to do this.
Step 2: Run the tests using the adapter
The easiest way to do this and immediately apply a debugger is the Debug tab in your project settings. Set this to start an external program, and the debugger will be attached to the program whenever you run it in debug mode.
If you use tests through VS:
devenv.exe /rootsuffix Exp
If you run tests through vstest.console.exe , and you do not install the adapter on your main VS:
vstest.console.exe dummy.project.with.tests.dll /TestAdapterPath:"TestAdapterBuildDirectory"
If you run tests through vstest.console.exe , and you did , install the adapter on your main VS:
vstest.console.exe dummy.project.with.tests.dll /UseVsixExtentions:true
Step 3. Attach the debugger to all the processes your adapter will work with
Use the Debug> Attach to Process option in Visual Studio.
In VS2013, most processes will hang between test runs, so you can run the test once to start the processes and then attach to them before running the tests again. In VS2015, these processes have no tendency to hang out for a long time, so you need to either attach them very quickly or add a big dream to your test performer to give you extra time to join.
If you connected to the correct process and your test adapters were compiled with characters, you should have no problem adding a breakpoint where you need to in the adapter code.
The processes you need to connect to are as follows
VS2013
devenv.exe - instance of VS. This will launch all the test container containers you create.vstest.discoveryengine.exe - The discovery process. This is where all the testing discoverers will be launched after sending the test containers.vstest.executionengine.exe - Execution process. Any test executors will be launched here after submitting test cases. Therefore, this is what you need to connect to if you want to see how the test passes.
VS2015
Some of these processes still exist, but you also need to attach to several processes, all called TE.ProcessHost.Managed.exe . If you donβt know which of these processes to join, join them all. Some of them will be detected, and some will be executed, although the execution processes will disappear very quickly.
vstest.console.exe
It does not use Test Discoverer or Discoverer to test the container. If you are connected to a specific console program, you can verify the tests performed by adding breakpoints to the test executor. If this does not work, I suspect that the adapter does not start at all, and you should take a closer look at the /TestAdapterPath and /UseVsixExtensions .