Skip to content

Background Attribute

Averrunci edited this page Jan 28, 2018 · 1 revision

This attribute is used to provide a description of a background for a fixture. Its target is a constructor of a fixture.

The available property is as follows.

Property Description
Description Specifies a description of a background for a fixture.

For example:

[Story("LoginAuthentication")]
class LoginAuthentication
{
    [Background("Navigate to the login page")]
    public LoginAuthentication()
    {
        TestNavigator.NavigateToLogin();
    }
}
Clone this wiki locally