Export (0) Print
Expand All

LoadTestContext Class

Encapsulates information about the context in which the load test is running.

System.Object
  Microsoft.VisualStudio.TestTools.LoadTesting.LoadTestContext

Namespace:  Microsoft.VisualStudio.TestTools.LoadTesting
Assembly:  Microsoft.VisualStudio.QualityTools.LoadTestFramework (in Microsoft.VisualStudio.QualityTools.LoadTestFramework.dll)

[SerializableAttribute]
public class LoadTestContext : IDictionary<string, Object>, 
	ICollection<KeyValuePair<string, Object>>, IEnumerable<KeyValuePair<string, Object>>, 
	IEnumerable

The LoadTestContext type exposes the following members.

  NameDescription
Public propertyAgentCountGets the total number of agents that are used in the load test run.
Public propertyAgentIdGets the one-based index for the current agent.
Public propertyAgentNameGets the name of the current agent.
Public propertyControllerNameGets the name of the computer that acts as the controller for the load test run.
Public propertyCountGets the number of elements that are contained in the LoadTestContext object.
Public propertyIsLocalRunGets a value that indicates whether the test was run locally or remotely.
Public propertyIsReadOnlyGets a value that indicates whether LoadTestContext is read-only.
Public propertyItemGets or sets a LoadTestContext element that has the specified key.
Public propertyKeysGets an ICollection<T> that contains the keys of the LoadTestContext elements.
Public propertyLoadTestRunIdGets the ID that is associated with this load test run. Set accessor is set to internal.
Public propertyValuesGets the ICollection<T> that contains the values in the LoadTestContext elements.
Top

  NameDescription
Public methodAdd(KeyValuePair<String, Object>)Adds a KeyValuePair<TKey, TValue> item to the LoadTestContext.
Public methodAdd(String, Object)Adds an element that has the provided key and value to the LoadTestContext.
Public methodClearRemoves all items from the LoadTestContext.
Public methodContainsDetermines whether the LoadTestContext contains a specific value.
Public methodContainsKeyIndicates whether the LoadTestContext contains an element that has the specified key.
Public methodCopyToCopies the elements of the LoadTestContext to an Array, starting at a particular Array index.
Public methodEqualsDetermines whether the specified Object is equal to the current Object. (Inherited from Object.)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public methodGetEnumeratorReturns an enumerator that iterates through the LoadTestContext.
Public methodGetHashCodeServes as a hash function for a particular type. (Inherited from Object.)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodRemove(KeyValuePair<String, Object>)Removes the first occurrence of a specific object from the LoadTestContext.
Public methodRemove(String)Removes the element that has the specified key from the LoadTestContext.
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Public methodTryGetValueGets the value that is associated with the specified key.
Top

This is a collection of context items and load test configurations used for storing information that is used by the load test.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Community Additions

ADD
Show:
© 2014 Microsoft