Table of Contents

Method TryGetTestCaseMetadata

Namespace
Xunit.Runner.Common
Assembly
xunit.v3.runner.common.dll

TryGetTestCaseMetadata(string, bool)

Attempts to retrieve ITestCaseMetadata from the cache (and optionally remove it).

public ITestCaseMetadata? TryGetTestCaseMetadata(string testCaseUniqueID, bool remove = false)

Parameters

testCaseUniqueID string

The unique ID of the test case to retrieve.

remove bool

Set to true to remove the metadata after retrieval.

Returns

The cached metadata, if present; or null if there isn't any.

TryGetTestCaseMetadata(ITestCaseMessage)

Attempts to retrieve ITestCaseMetadata from the cache.

public ITestCaseMetadata? TryGetTestCaseMetadata(ITestCaseMessage message)

Parameters

message

The message that indicates which metadata to retrieve.

Returns

The cached metadata, if present; or null if there isn't any.