Hi,
we are running our unit tests in teamcity and use typemock as our mocking framework. For some reasons one test fail when running on teamcity.
If we ignore this test another will fail
If we run this test in visual stuidio everything its ok
If we run this on server with TMock runner its ok
but not when we running this test with <Nunit or Exec Command="$(teamcity_dotnet_nunitlauncher)
If we will use the TMock runner we do not have any possibility to use the integration in teamcity.
Typemock version: 7.4.1
TeamCity 8.0 (build 27402)
thanks for help,
Moritz
MSBuild-Script:
<Project DefaultTargets="Typemock" xmlns="
http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project ="$(TypemockLocation)TypeMock.MSBuild.Tasks"/>
<ItemGroup>
<TestAssembly Include="$(Testpath)" />
</ItemGroup>
<Target Name="Typemock">
<TypemockStart />
<Exec Command="$(teamcity_dotnet_nunitlauncher) $(TargetFramework) $(NUnitPlatform) $(NUnitVersion) %(TestAssembly.Identity)" />
<TypemockStop />
</Target>
</Project>
Error-Message:
[Step 2/2] GDVDL.Adapter.eCall.Tests.dll (40s)
[16:02:54][GDVDL.Adapter.eCall.Tests.dll] GDVDL.Adapter.eCall.Tests.ECallProtokollTests.Given_Successful_Registration_For_ECallStatus_Polling_When_Deregistration_Is_Send_Then_Stop_Polling (1s)
[16:02:55][GDVDL.Adapter.eCall.Tests.ECallProtokollTests.Given_Successful_Registration_For_ECallStatus_Polling_When_Deregistration_Is_Send_Then_Stop_Polling] Test(s) failed. System.Reflection.TargetInvocationException : Ein Aufrufziel hat einen Ausnahmefehler verursacht. ----> TypeMock.TypeMockException : *** No method with name Given_Successful_Registration_For_ECallStatus_Polling_When_Deregistration_Is_Send_Then_Stop_Polling>b__4e in type GDVDL.Adapter.eCall.Tests.ECallProtokollTests exists.
/// This not existing method is the method with the Test-attribute