Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

PrivateObject.GetField Method (String)

 

Gets a value from a named field, based on the name.

Namespace:   Microsoft.VisualStudio.TestTools.UnitTesting
Assembly:  Microsoft.VisualStudio.QualityTools.UnitTestFramework (in Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll)

public object GetField(
	string name
)

Parameters

name
Type: System.String

The name of the private field to get.

Return Value

Type: System.Object

The value set for the name field.

Exception Condition
ArgumentException

name is null or empty.

Return to top
Show: