1

今朝、Gallio と Team City の統合の問題について質問しました。msbuild ファイルを変更して、最新の Gallio ビルド スクリプト API で適切な構文を使用するようにしました。Jeff Brown に感謝しますが、Team City でアプリケーションをビルドしようとすると、次のエラーが表示されます。

Gallio タスクの実行中に予期しないエラーが発生しました。 work\fa1d38b0af329d65\CoderForTraders.msbuild (9、9): FilterParseException: コロンが必要です

これが9行目です:

<Gallio IgnoreFailures="true" Filter="Type=SomeFixture" Files="@(TestFile)">

そして、ここにファイル全体があります:

<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 test files and assemblies -->
    <ItemGroup>
      <TestFile Include="C:\_CBL\CBL\CoderForTraders\Source\trunk\UnitTest\DomainModel.Tests\bin\Debug\CBL.CoderForTraders.DomainModel.Tests.dll" />
    </ItemGroup>
    <Target Name="RunTests">
        <Gallio IgnoreFailures="true" Filter="Type=SomeFixture" Files="@(TestFile)">
            <!-- 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>

考えられる問題について考えがありますか?

4

3 に答える 3

3

はい、フィルター属性が正しくない構文で指定されました。キーは、コロンを使用してその値から分離する必要があります。例えば。「Type:SomeFixture」を使用することは有効です。もちろん、SomeFixture というテスト フィクスチャが実際にない限り、おそらくそのフィルタを使用したくないでしょう。:-p

于 2010-04-10T09:53:32.423 に答える
0

ついに手に入れました!

Filter 属性を削除したところ、テストが適切に実行され、すべて正常に動作するようになりました

于 2010-04-09T20:45:31.013 に答える
0

Command in Bamboo を使用したところ、/filter 引数からスペースを削除すると、これが解決したことがわかりました。

于 2014-05-09T09:34:55.220 に答える