Class PlatformAttribute
Marks an assembly, test fixture or test method as applying to a specific platform.
Implements
Inherited Members
Namespace: NUnit.Framework
Assembly: nunit.framework.dll
Syntax
[AttributeUsage(AttributeTargets.Assembly|AttributeTargets.Class|AttributeTargets.Method, AllowMultiple = true, Inherited = false)]
public class PlatformAttribute : IncludeExcludeAttribute, IApplyToTest
  Constructors
View SourcePlatformAttribute()
Constructor with no platforms specified, for use with named property syntax.
Declaration
public PlatformAttribute()
  PlatformAttribute(string?)
Constructor taking one or more platforms
Declaration
public PlatformAttribute(string? platforms)
  Parameters
| Type | Name | Description | 
|---|---|---|
| string | platforms | Comma-delimited list of platforms  | 
      
Methods
View SourceApplyToTest(Test)
Causes a test to be skipped if this PlatformAttribute is not satisfied.
Declaration
public void ApplyToTest(Test test)
  Parameters
| Type | Name | Description | 
|---|---|---|
| Test | test | The test to modify  |