How do I add a VSTO project as a reference to a unit testing project?

Posted by Mathias on Stack Overflow See other posts from Stack Overflow or by Mathias
Published on 2010-03-19T02:51:30Z Indexed on 2010/03/19 3:01 UTC
Read the original article Hit count: 215

Filed under:
|

In order not to pollute my projects with unit tests, I like to create a separate project for my unit tests; I add a reference to the project under test in the unit tests project. However, this isn't working that well with my VSTO excel add-in projects: when I create a separate unit test project and go to Add Reference > Projects, there is no project to pick.
What I have done so far is Add Reference > Browse, and pick the add-in dll from the debug folder. I have also run into issues from time to time with this, with the reference suddenly not working, requiring to remove/re-add the dll reference.
Can anybody explain why a VSTO project doesn't show up as a regular project? And is there a better way to go about it than what I am doing presently?

© Stack Overflow or respective owner

Related posts about vsto

Related posts about unit-testing