I'm using NUnit
with AutoFixture
, AutoMoq
and the Theory
attribute.
Here is my test method,
[TestFixture]
public class TestClass
{
[Theory, AutoMoqData]
public void TestI(I i)
{ }
}
the interface
public interface I
{ }
and the attribute
public class AutoMoqDataAttribute : AutoDataAttribute
{
public AutoMoqDataAttribute()
: base(new Fixture().Customize(new AutoMoqCustomization()))
{ }
}
When I build my solution the test is discovered. When I run the test the following is written to the Output window:
NUnit 1.0.0.0 executing tests is started
Run started: [...].Test.dll
NUnit 1.0.0.0 executing tests is finished
Test adapter sent back a result for an unknown test case. Ignoring result for 'TestI(Mock<TestClass+I:1393>.Object)'.
When using xUnit.net
the above test is run correctly. Why is not it working with NUnit
?
I have the following Nuget packages installed in the test project:
- AutoFixture 3.18.1
- AutoFixture.AutoMoq 3.18.1
- Moq 4.2.1402.2112
- NUnit 2.6.3
- NUnitTestAdapter 1.0
I'm running the test from within Visual Studio 2013 Professional. I also tried running the test in the separate GUI runner, with the same result.