As a developer focused on quality, I write code to test code but from time to time you get into issues that you just don’t understand what is going on more importantly how to fix it. In this case, all I wanted to do is associate a VSO Test Case to an automated test (unit test). I’ve done this in the past many times with success but this one just stumbles me. All of the steps are documented in this article:
How to: Associate an Automated Test with a Test Case
However, the steps are not working for me and all I get when I click on the ellipses is a blank window.
- Cleaning my solution and rebuilding
- Ensure that my tests have the proper attributes bound. E.g. [TestMethod]
- Ensured that it’s a managed test project
All of which works. As a last resort, I opened another test project and surprisingly enough I was able to select an automated test. I compared the project file (via text editor) and noticed that my actual test project is missing the projectype xml entry. Now I remember that when I generated my test project, I started off as a class library. I then manually referenced all the VS Unit Testing frameworks, created my unit tests and everything worked fine EXCEPT for associating an automated test to a test case.
Open up your project file in a text editor (Notepad)
Add the following under the <PropertyGroup> node
Save the project file, reload your project and rebuild.
Now you should be able to Associate test cases: