Table of Contents

Method TryGetMethodMetadata

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

TryGetMethodMetadata(string, bool)

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

public ITestMethodMetadata? TryGetMethodMetadata(string testMethodUniqueID, bool remove = false)

Parameters

testMethodUniqueID string

The unique ID of the test method 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.

TryGetMethodMetadata(ITestMethodMessage)

Attempts to retrieve ITestMethodMetadata from the cache.

public ITestMethodMetadata? TryGetMethodMetadata(ITestMethodMessage message)

Parameters

message

The message that indicates which metadata to retrieve.

Returns

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