Table of Contents

Class FeatureAttribute

Namespace
TinyBDD
Assembly
TinyBDD.dll

Marks a test class as a BDD Feature, providing a human-friendly name and an optional description.

[AttributeUsage(AttributeTargets.Class, Inherited = false)]
public sealed class FeatureAttribute : Attribute
Inheritance
FeatureAttribute
Inherited Members

Examples

[Feature("Shopping Cart", "Customers can add and remove items")]
public class CartTests : TinyBddXunitBase { /* ... */ }

Remarks

Constructors

FeatureAttribute(string, string?)

Creates a new FeatureAttribute.

public FeatureAttribute(string name, string? description = null)

Parameters

name string

The feature name to display in reports.

description string

Optional human-readable description shown under the feature.

Properties

Description

Optional feature description shown beneath the feature name.

public string? Description { get; }

Property Value

string

Name

The user-facing feature name displayed in reports.

public string Name { get; }

Property Value

string

See Also