多天来,我一直在尝试让我的MBUnit测试套件在Team City上工作,但没有取得任何成功。
我的解决方案不会产生任何问题。我的测试里有这个程序。在谷歌上搜索了Gallio与Team City的集成后,我尝试了很多方法来让它工作,我想我已经很接近了,但需要帮助。
我已经将gallio bin目录包含到我的存储库和TC Server中。
下面是我在Team City中设置的build runner:
生成运行器: MSBuild生成文件路径: Myproject.msbuild目标: RebuildSolution RunTests
下面是我创建并包含在源代码控制主干目录中的Myproject.msbuild文件:
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!-- This is needed by MSBuild to locate the Gallio task -->
<UsingTask AssemblyFile="C:\Gallio\bin\Gallio.MSBuildTasks.dll" TaskName="Gallio" />
<!-- Specify the tests assemblies -->
<ItemGroup>
<TestAssemblies Include="C:\_CBL\CBL\CoderForTraders\Source\trunk\UnitTest\DomainModel.Tests\bin\Debug\CBL.CoderForTraders.DomainModel.Tests.dll" />
</ItemGroup>
<Target Name="RunTests">
<Gallio IgnoreFailures="false" Assemblies="@(TestAssemblies)" RunnerExtensions="TeamCityExtension,Gallio.TeamCityIntegration">
<!-- This tells MSBuild to store the output value of the task's ExitCode property into the project's ExitCode property -->
<Output TaskParameter="ExitCode" PropertyName="ExitCode"/>
</Gallio>
<Error Text="Tests execution failed" Condition="'$(ExitCode)' != 0" />
</Target>
<Target Name="RebuildSolution">
<Message Text="Starting to Build"/>
<MSBuild Projects="CoderForTraders.sln"
Properties="Configuration=Debug"
Targets="Rebuild" />
</Target>
</Project>以下是Team City显示的错误:
错误MSB4064:"Gallio“任务不支持"Assemblies”参数。验证任务上是否存在该参数,以及它是否为可设置的公共实例属性
错误MSB4063:无法使用其输入参数初始化"Gallio“任务。
谢谢你的帮忙
发布于 2010-04-10 02:27:13
程序集属性已重命名为Files。这里的文档:http://www.gallio.org/api/html/T_Gallio_MSBuildTasks_Gallio.htm
https://stackoverflow.com/questions/2607963
复制相似问题