24 October 2011

How Do I Make My Build and/or Test Servers Use Pex and Moles?

All build and test servers (e.g. MSBuild) that must handle Pex and/or Moles have the Pex and Moles Framework installed.  After installation, the builds and tests should execute normally.


  1. Do you happen to have any guidance on Team Development with Pex and Moles? Each time I re-build my development workstation, I get all types of Moles assembly reference errors. I have not found any good way to resolve this issue other than constantly deleting and re-adding all of the Moles assemblies in each of the failing Visual Studio projects. If there is a better way, please let me know.


    1. No, I am not aware of any solutions to this issue.

      However, you may want to ensure the "Moled Assemblies" directory is not being committed to your source control provider.

      A kludge solution may be to create a script that deletes all "Moled Assemblies" directories, throughout your root projects directory. This ensures the offending moled assemblies are rebuilt.


Please provide details, when posting technical comments. If you find an error in sample code or have found bad information/misinformation in a post, please e-mail me details, so I can make corrections as quickly as possible.