<PackageReference Include="NUnit" Version="5.0.0-beta.1" />

NUnit.Framework.MaxTimeAttribute

Specifies the maximum time (in milliseconds) for a test case to succeed.
public int WarningTime { get; set; }

Gets or sets an optional warning threshold in milliseconds. If the test takes longer than this time, but less than the maximum time, a warning is issued.

public MaxTimeAttribute(int milliseconds)

Construct a MaxTimeAttribute, given a time in milliseconds.