Search code examples
.netunit-testingcompact-framework

Unit testing of .NET CF application on .NET Full framework


How can I create in Visual Studio 2008 unit tests running on .NET Full Framework for some non-visual classes of .NET CF 3.5 application

Or it is only possible to test this calsses in Emulator?


Solution

  • You can't get the full framework mstest infrastructure to load up a CF assembly (not with any easy anyway). Generally speaking, this is what we do for unit testing non UI, non-CF-specific CF code.

    1. Create a full-framework Class Library project
    2. Add the source files from your CF project
    3. Create a Unit Test project for the full-framework project
    4. Run the Unit tests