BUG: Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll is required

Vote:
 

Hello!

I installed EPiServer CMS 6 pre-release on test server with IIS 7 only (no Visual Studio).

It looks like dll in EPiServer references to Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll.

After the deployment of the website this error appear:

Could not load file or assembly 'Microsoft.VisualStudio.QualityTools.UnitTestFramework, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.

Stack trace:

[FileNotFoundException: Could not load file or assembly 'Microsoft.VisualStudio.QualityTools.UnitTestFramework, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.]
   System.ModuleHandle.ResolveType(Int32 typeToken, RuntimeTypeHandle* typeInstArgs, Int32 typeInstCount, RuntimeTypeHandle* methodInstArgs, Int32 methodInstCount) +0
   System.ModuleHandle.ResolveTypeHandle(Int32 typeToken, RuntimeTypeHandle[] typeInstantiationContext, RuntimeTypeHandle[] methodInstantiationContext) +227
   System.Reflection.Module.ResolveType(Int32 metadataToken, Type[] genericTypeArguments, Type[] genericMethodArguments) +355
   System.Reflection.CustomAttribute.FilterCustomAttributeRecord(CustomAttributeRecord caRecord, MetadataImport scope, Assembly& lastAptcaOkAssembly, Module decoratedModule, MetadataToken decoratedToken, RuntimeType attributeFilterType, Boolean mustBeInheritable, Object[] attributes, IList derivedAttributes, RuntimeType& attributeType, RuntimeMethodHandle& ctor, Boolean& ctorHasParameters, Boolean& isVarArg) +474
   System.Reflection.CustomAttribute.IsCustomAttributeDefined(Module decoratedModule, Int32 decoratedMetadataToken, RuntimeType attributeFilterType, Boolean mustBeInheritable) +630
   System.Reflection.CustomAttribute.IsDefined(RuntimeType type, RuntimeType caType, Boolean inherit) +100
   Microsoft.Internal.AttributeServices.IsAttributeDefined(ICustomAttributeProvider attributeProvider) +140
   System.ComponentModel.Composition.AttributedModel.AttributedPartCreationInfo.IsPartDiscoverable() +65
   System.ComponentModel.Composition.AttributedModel.AttributedModelDiscovery.CreatePartDefinitionIfDiscoverable(Type type, ICompositionElement origin) +138
   System.ComponentModel.Composition.Hosting.TypeCatalog.get_PartsInternal() +397
   System.ComponentModel.Composition.Hosting.TypeCatalog.CreateIndex() +168
   System.Lazy`1.get_Value() +163
   System.ComponentModel.Composition.Hosting.TypeCatalog.GetCandidateParts(ImportDefinition definition) +234
   System.ComponentModel.Composition.Hosting.TypeCatalog.GetExports(ImportDefinition definition) +204
   System.ComponentModel.Composition.Hosting.AssemblyCatalog.GetExports(ImportDefinition definition) +81
   System.ComponentModel.Composition.Hosting.AggregateCatalog.GetExports(ImportDefinition definition) +353
   System.ComponentModel.Composition.Hosting.CatalogExportProvider.GetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition) +274
   System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1& exports) +145
   System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(ImportDefinition definition, AtomicComposition atomicComposition) +158
   System.ComponentModel.Composition.Hosting.AggregateExportProvider.GetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition) +368
   System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1& exports) +145
   System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExports(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1& exports) +130
   System.ComponentModel.Composition.Hosting.CompositionContainer.GetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition) +126
   System.ComponentModel.Composition.Hosting.ExportProvider.TryGetExportsCore(ImportDefinition definition, AtomicComposition atomicComposition, IEnumerable`1& exports) +145
   System.ComponentModel.Composition.Hosting.ExportProvider.GetExports(ImportDefinition definition, AtomicComposition atomicComposition) +158
   System.ComponentModel.Composition.Hosting.ImportEngine.TryGetExports(ExportProvider provider, ComposablePart part, ImportDefinition definition, AtomicComposition atomicComposition) +180
   System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportSubset(PartManager partManager, IEnumerable`1 imports, AtomicComposition atomicComposition) +531
   System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImportsStateMachine(PartManager partManager, ComposablePart part) +1169
   System.ComponentModel.Composition.Hosting.ImportEngine.TrySatisfyImports(PartManager partManager, ComposablePart part, Boolean shouldTrackImports) +438
   System.ComponentModel.Composition.Hosting.ImportEngine.SatisfyImports(ComposablePart part) +276
   System.ComponentModel.Composition.Hosting.<>c__DisplayClass2.<Compose>b__0() +76
   System.ComponentModel.Composition.Hosting.CompositionServices.TryInvoke(Action action) +96
   System.ComponentModel.Composition.Hosting.ComposablePartExportProvider.Compose(CompositionBatch batch) +1799
   System.ComponentModel.Composition.Hosting.CompositionContainer.Compose(CompositionBatch batch) +119
   System.ComponentModel.Composition.AttributedModelServices.ComposeParts(CompositionContainer container, Object[] attributedParts) +454
   EPiServer.Framework.Initialization.InitializationModule.StaticInitialization(HostType hostType) +206
   EPiServer.Framework.Initialization.InitializationModule.FrameworkInitialization(HostType hostType) +53
   EPiServer.Global..ctor() +76
   Maggie.Web.Global..ctor() +41
   ASP.global_asax..ctor() +9

[TargetInvocationException: Exception has been thrown by the target of an invocation.]
   System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandle& ctor, Boolean& bNeedSecurityCheck) +0
   System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean fillCache) +146
   System.RuntimeType.CreateInstanceImpl(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean fillCache) +298
   System.Activator.CreateInstance(Type type, Boolean nonPublic) +79
   System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes) +10364331
   System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +258
   System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +382

[HttpException (0x80004005): Exception has been thrown by the target of an invocation.]
   System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +11297830
   System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +88
   System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +4336948

#36255
Jan 21, 2010 16:24
Vote:
 

Does your bin folder contain an assembly "Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll"? Try removing it and see what happens.

#36271
Jan 22, 2010 9:33
Vote:
 

Hello Cristian. Thank you for the fast response and tool you provided.

My bin folder doesn't contain "Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll". That's why i caught this exception.

If it present everything works fine.

Using your tool I found the library referenced to "Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll". It's "Bonnier.Common.Tests, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null".

It was placed into "bin" by our mistake. So I just removed both assemblies.

Issue is solved. Thank you again!

#36310
Jan 25, 2010 13:07
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.