I'm using xunit v2.1.0, xunit.extensions v1.8.0.1549, AutoFixture v3.40.0, AutoFixture.Xunit v3.40.0 and I have this simple trivial test that uses AutoData
using Ploeh.AutoFixture.Xunit;
using Xunit;
namespace Tests
{
public class ToolTests
{
[Theory, AutoData]
public void Test(int foo)
{
Assert.NotEqual(0, foo);
}
}
}
And the error that I get in Resharper (v9.2) test runner is
System.InvalidOperationException No data found for Tests.ToolTests.Test Exception doesn't have a stacktrace
I've noticed that xunit.extensions is not the last version (currently v2.0.0), but when I try to update given nuget package I get error:
Unable to resolve dependencies. 'xunit.extensions 2.0.0' is not compatible with 'AutoFixture.Xunit 3.40.0 constraint: xunit.extensions (≥ 1.8.0.1549 && < 2.0.0)'
Any clues why this is happening?
You have to use the AutoFixture.Xunit2
package, instead of the AutoFixture.Xunit
when you're using xUnit 2.0 or above.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With