iOS Guides | Samples

NUnit.Framework.CategoryAttribute Class

Attribute used to apply a category to a test

See Also: CategoryAttribute

Syntax

[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Method, AllowMultiple=true, Inherited=true)]
public class CategoryAttribute : NUnitAttribute, IApplyToTest

Requirements

Namespace: NUnit.Framework
Assembly: NUnitLite (in NUnitLite.dll)
Assembly Versions: 1.0.0.0

The members of NUnit.Framework.CategoryAttribute are listed below.

See Also: NUnitAttribute

Public Constructors

Construct attribute for a given category based on a name. The name may not contain the characters ',', '+', '-' or '!'. However, this is not checked in the constructor since it would cause an error to arise at as the test was loaded without giving a clear indication of where the problem is located. The error is handled in NUnitFramework.cs by marking the test as not runnable.

Protected Constructors

Protected constructor uses the Type name as the name of the category.

Protected Fields

categoryNameString. The name of the category

Public Properties

[read-only]
NameString. The name of the category

Public Methods