Building MVVM Light from Codeplex

In order to build the latest version of the source code for MVVM Light, follow the indications:

Getting the source

Building the source

  • Locate the Zip file you just downloaded (named something like “mvvmlight-5056f53e22e0.zip”).
  • Right click the file and select Properties.
  • If the “Unblock” button is visible in the Properties dialog, click it.
  • Extract the content of the Zip file.
  • Locate and open GalaSoft.MvvmLight.sln (this file is located in the GalaSoft.MvvmLight folder). Alternatively, you can select a specific configuration (.NET, Silverlight, Windows Phone, etc).
  • Build the solution. You can select either the Debug or Release configuration (or both).

Running unit tests

MVVM Light’s tests can be run in MSTEST directly in Visual Studio. However, the tests in the .NET4 version of MVVM Light may fail if you leave the assemblies signed. To remove the signing of the assemblies, follow the steps:

  • Open the solution GalaSoft.MvvmLight (NET4).sln.
  • Right click on the project GalaSoft.MvvmLight (NET4) in the Solution Explorer and select Properties from the context menu.
  • Select the tab Signing.
  • Uncheck the checkbox labeled Sign the assembly.
  • Repeat this for the project GalaSoft.MvvmLight.Extras (NET4).
  • Run the tests with the menu Test, Run, All Tests in Solution.
  • After the tests are run, recheck both checkboxes labeled Sign the assembly.
  • Rebuild the projects.