ReSharper 2026.1 Help

Code inspection: NUnit.AutoFixture. Incompatible argument type or incorrect argument value.

This inspection reports [InlineAutoData(...)] arguments whose values are not compatible with the corresponding test method parameter type. It can also appear when the supplied value is syntactically valid but still cannot be used as that parameter type by AutoFixture's NUnit integration.

Example

The attribute data does not match the test signature, so the test case is misleading and may fail before the test body even runs.

[Test] [InlineAutoData("100")] public void TestCount(int count) { }
[Test] [InlineAutoData(100)] public void TestCount(int count) { }
31 March 2026