D
drozd
Hi,
How do you approach managing MSTest unit tests in smart device
projects (VS2008)?
Do you keep 2 separate test projects
- one set up to reference the smart device test framework
- another using the full framework one
with shared unit tests added as links to the other project.
Or do you only maintain one project and two separate test run config
files?
So far I've been going with the first approach, but it's really
annoying to have to "Add as link.." every time I add a new test class
and also to constantly unload/reload one of the projects (because VS
doesn't like tests with the same name/id loaded at the same time).
The problem with the second approach is that you can't really use the
TestContext in the test classes, because running the tests with the
other test run config will get you:
" System.ArgumentException: Object of type
'Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestAdapterContext'
cannot be converted to type
'Microsoft.VisualStudio.TestTools.UnitTesting.TestContext"
What's your take on this?
Best regards,
Michal
How do you approach managing MSTest unit tests in smart device
projects (VS2008)?
Do you keep 2 separate test projects
- one set up to reference the smart device test framework
- another using the full framework one
with shared unit tests added as links to the other project.
Or do you only maintain one project and two separate test run config
files?
So far I've been going with the first approach, but it's really
annoying to have to "Add as link.." every time I add a new test class
and also to constantly unload/reload one of the projects (because VS
doesn't like tests with the same name/id loaded at the same time).
The problem with the second approach is that you can't really use the
TestContext in the test classes, because running the tests with the
other test run config will get you:
" System.ArgumentException: Object of type
'Microsoft.VisualStudio.TestTools.TestTypes.Unit.UnitTestAdapterContext'
cannot be converted to type
'Microsoft.VisualStudio.TestTools.UnitTesting.TestContext"
What's your take on this?
Best regards,
Michal