ReSharper
 
Get ReSharper
Get your hands on the new features ahead of the release by joining the Early Access Program for ReSharper 2025.1! Learn more

Code inspection: NUnit. Specified attribute values produce too many tests.

Last modified: 11 February 2024

When you specify values for your tests with Range, Random, or Values attributes or create combinations of values with Combinatorial, Sequential, or Pairwise attributes, you may end up having too many tests. For example:

Assuming that this number of tests is not what you expect, ReSharper issues a warning about too many tests. By default, ReSharper limits the maximum number of tests to 1000 and it is not configurable in the default UI. However, if you want to change this limit, you can Run ReSharper in the internal mode and use the Skip parameterized test after input data exceeds [x] items option on the Tools | Unit Testing | General page of ReSharper options Alt+R, O.