Article ID: 948816 - View products that this article applies to.
You add the following TestContainer items to a test project on a Team Foundation Server 2008 Build server. Then, you run the project by using test containers.
When you do this, all unit tests in assemblies that match the *.Tests.dll pattern run successfully. However, when you run a .webtest file or a .loadtest file, you may receive an error message that resembles the following:
Using "TestToolsTask" task from assembly "C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\PrivateAssemblies\Microsoft.VisualStudio.QualityTools.MSBuildTasks.dll". Task "TestToolsTask"
warning MSB4018: The "TestToolsTask" task failed unexpectedly.
warning MSB4018: System.BadImageFormatException: Could not load file or assembly 'file:///C:BuildProjectTestService.ContinuousBinariesReleaseWebTest1.webtest' or one of its dependencies. The module was expected to contain an assembly manifest.
warning MSB4018: File name: 'file:///C:BuildProjectTestService.ContinuousBinariesReleaseWebTest1.webtest'
warning MSB4018:at System.Reflection.Assembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
warning MSB4018: at System.Reflection.Assembly.nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, Assembly locationHint, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, Boolean forIntrospection)
warning MSB4018: at System.Reflection.Assembly.InternalLoad(AssemblyName assemblyRef, Evidence assemblySecurity, StackCrawlMark& stackMark, Boolean forIntrospection)
warning MSB4018: at System.Reflection.Assembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, StackCrawlMark& stackMark)
warning MSB4018: at System.Reflection.Assembly.LoadFrom(String assemblyFile)
warning MSB4018: at Microsoft.Build.Tasks.TestToolsTask.GetUTFVersionFromAssembly(String assemblyName, Int32 version)
warning MSB4018: at Microsoft.Build.Tasks.TestToolsTask.Execute()
warning MSB4018: at Microsoft.Build.BuildEngine.TaskEngine.ExecuteInstantiatedTask(EngineProxy engineProxy, ItemBucket bucket, TaskExecutionMode howToExecuteTask, ITask task, Boolean& taskResult)
This problem occurs if the .loadtest file or the .webtest file is an XML file. These files are used as the parameters to the Assembly.LoadFrom function. However, the Assembly.LoadFrom function expects to receive assemblies for its parameters.
Service pack informationTo resolve this problem, obtain the latest service pack for Visual Studio 2008 Team Foundation. For more information, visit the following Microsoft Web site:
Hotfix informationA supported hotfix is now available from Microsoft. However, it is intended to correct only the problem that is described in this article. Apply it only to systems that are experiencing this specific problem. This hotfix may receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next Visual Studio 2008 Team Foundation Server service pack that contains this hotfix.
To resolve this problem immediately, contact Microsoft Customer Support Services to obtain the hotfix. For a complete list of Microsoft Customer Support Services telephone numbers and information about support costs, visit the following Microsoft Web site:
http://support.microsoft.com/contactus/?ws=supportNote In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.
PrerequisitesNo prerequisites are required.
Restart requirementYou do not have to restart the computer after you apply this hotfix.
Hotfix replacement informationThis hotfix does not replace any other hotfixes.
File informationThe English version of this hotfix has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time item in Control Panel.
Collapse this tableExpand this table
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:
(http://support.microsoft.com/kb/824684/ )Description of the standard terminology that is used to describe Microsoft software updates
Contact us for more help
Connect with Answer Desk for expert help.