<PackageReference Include="NUnit" Version="4.1.0" />

IApplyToContext

public interface IApplyToContext
The IApplyToContext interface is implemented by attributes that want to make changes to the execution context before a test is run.
using NUnit.Framework.Internal; using System.Runtime.CompilerServices; namespace NUnit.Framework.Interfaces { [System.Runtime.CompilerServices.NullableContext(1)] public interface IApplyToContext { void ApplyToContext(TestExecutionContext context); } }