2012-09-04 17 views
5

Sto provando a configurare il nostro Hundson Server per CI il nostro nuovo progetto. Tutto gira bene, costruendo il progetto, i test unitari e le corse di controlli FxCop. Ma quando provo a verificare il codice con StyleCop si verifica un errore. Primo: sviluppiamo in C# con MS VS 2010 e sul server Hudson ci sono .Net 4.0 e Windows SDK 7.1 installato.StyleCopTask non può essere caricato su Hudson Server

Ora ho aggiunto StyleCop.Targets al mio SVN e ho collegato i file .cproj al file . Se io costruisco in VS2010 everythin andato bene, ad eccezione degli avvisi StyleCop, ma se il Hundson Server tenta di costruire il progetto si verifica questo errore:

error MSB4062: The "StyleCopTask" task could not be loaded from the assembly 
C:\Program Files (x86)\MSBuild\..\StyleCop 4.7\StyleCop.dll. Could not load file or 
assembly 'Microsoft.Build.Utilities.v3.5, Version=3.5.0.0, Culture=neutral, 
PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot 
find the file specified. Confirm that the <UsingTask> declaration is correct, 
that the assembly and all its dependencies are available, and that the task 
contains a public class that implements Microsoft.Build.Framework.ITask. 

Lo StyleCop.dll si trova nel percorso sul Hundson Server, qualcuno può dirmi cosa ho fatto di sbagliato?

+1

ho t lo ho stimato sul mio PC di sviluppo. Lì l'attività stylecop viene eseguita normalmente. Ho aggiunto in ogni file .csproj: CoolKiffings

+1

Sembra che StyleCop stia cercando un assembly .NET 3.5. Il server di build ha installato .NET 3.5? –

risposta

0
  1. Vai a Pannello di controllo \ Programmi \ Programmi e funzionalità
  2. Selezionare Attiva funzionalità di Windows on o off
  3. Fare clic sul .NET Framework 3.5 (include .NET 2.0 e 3.0)
  4. Fare clic su OK e attendere
  5. Riavviare Visual Studio

Questo dovrebbe risolvere il problema

Problemi correlati