Język

PlannedTest.DeclaringFilePath Właściwość

Definicja

Pobiera ścieżkę pliku źródłowego, która deklaruje test. Ta wartość jest przechwytywana w czasie kompilacji przez TestMethodAttributeelement ; może to być null , gdy test jest zadeklarowany za pomocą niestandardowego atrybutu metody testowej, który nie propaguje informacji o obiekcie wywołującym.

public string? DeclaringFilePath { get; }
[System.Runtime.CompilerServices.Nullable(2)]
public string? DeclaringFilePath { get; }
member this.DeclaringFilePath : string
[<System.Runtime.CompilerServices.Nullable(2)>]
member this.DeclaringFilePath : string
Public ReadOnly Property DeclaringFilePath As String

Wartość właściwości

Atrybuty

Dotyczy