Class ApplicationAttribute

Namespace
ProtoTest.Core
Assembly
ProtoTest.Core.dll

Selects the application under test for a test or class and, optionally, which registered client each protocol uses. Bindings use Protocol:Client (for example Rest:Billing or Web:Admin); unlisted protocols use the application's first registered client of that protocol.

[AttributeUsage(AttributeTargets.Class|AttributeTargets.Method, AllowMultiple = false, Inherited = true)]
public sealed class ApplicationAttribute : ProtoAttribute
Inheritance
ApplicationAttribute
Inherited Members
Extension Methods

Constructors

ApplicationAttribute(string, params string[])

public ApplicationAttribute(string name, params string[] clients)

Parameters

name string
clients string[]

Properties

Bindings

Gets the protocol-to-client bindings, keyed by protocol name.

public IReadOnlyDictionary<string, string> Bindings { get; }

Property Value

IReadOnlyDictionary<string, string>

Name

Gets the application name.

public string Name { get; }

Property Value

string

Methods

BeforeTestAsync(ProtoExecutionContext)

Executed asynchronously before the decorated test or class tests execute.

public override Task BeforeTestAsync(ProtoExecutionContext context)

Parameters

context ProtoExecutionContext

Returns

Task