C# Class System.Collections.Tests.IList_NonGeneric_Tests

Contains tests that ensure the correctness of any class that implements the nongeneric IList interface
显示文件 Open project: dotnet/corefx

Protected Methods

Method Description
AddToCollection ( ICollection collection, int numberOfItemsToAdd ) : void
AddToCollection ( IList collection, int numberOfItemsToAdd ) : void
CreateT ( int seed ) : object

Creates an object that is dependent on the seed given. The object may be either a value type or a reference type, chosen based on the value of the seed.

NonGenericICollectionFactory ( ) : ICollection
NonGenericICollectionFactory ( int count ) : ICollection
NonGenericIListFactory ( ) : IList

Creates an instance of an IList that can be used for testing.

NonGenericIListFactory ( int count ) : IList

Creates an instance of an IList that can be used for testing.

Private Methods

Method Description
IListNonGeneric_Remove_OnReadOnlyCollection_ThrowsNotSupportedException ( int count ) : void
IList_NonGeneric_Add_AfterCallingClear ( int count ) : void
IList_NonGeneric_Add_AfterRemoving ( int count ) : void
IList_NonGeneric_Add_AfterRemovingAllItems ( int count ) : void
IList_NonGeneric_Add_AfterRemovingAnyValue ( int count ) : void
IList_NonGeneric_Add_DuplicateValue ( int count ) : void
IList_NonGeneric_Add_InvalidValueToBeginningOfCollection ( int count ) : void
IList_NonGeneric_Add_InvalidValueToEndOfCollection ( int count ) : void
IList_NonGeneric_Add_InvalidValueToMiddleOfCollection ( int count ) : void
IList_NonGeneric_Add_Null ( int count ) : void
IList_NonGeneric_Add_ToReadOnlyCollection ( int count ) : void
IList_NonGeneric_Clear ( int count ) : void
IList_NonGeneric_Contains_InvalidValue_ThrowsArgumentException ( int count ) : void
IList_NonGeneric_Contains_NullOnCollectionContainingNull ( int count ) : void
IList_NonGeneric_Contains_NullOnCollectionNotContainingNull ( int count ) : void
IList_NonGeneric_Contains_ValidValueOnCollectionNotContainingThatValue ( int count ) : void
IList_NonGeneric_Contains_ValidValueThatExistsTwiceInTheCollection ( int count ) : void
IList_NonGeneric_IList_NonGeneric_Contains_ValidValueOnCollectionContainingThatValue ( int count ) : void
IList_NonGeneric_IndexOf_EachValueNoDuplicates ( int count ) : void
IList_NonGeneric_IndexOf_InvalidValue ( int count ) : void
IList_NonGeneric_IndexOf_NullContainedInList ( int count ) : void
IList_NonGeneric_IndexOf_NullNotContainedInList ( int count ) : void
IList_NonGeneric_IndexOf_ReturnsFirstMatchingValue ( int count ) : void
IList_NonGeneric_IndexOf_ValueInCollectionMultipleTimes ( int count ) : void
IList_NonGeneric_Insert_DuplicateValues ( int count ) : void
IList_NonGeneric_Insert_FirstItemToNonNull ( int count ) : void
IList_NonGeneric_Insert_FirstItemToNull ( int count ) : void
IList_NonGeneric_Insert_IndexGreaterThanListCount_Appends ( int count ) : void
IList_NonGeneric_Insert_InvalidValue ( int count ) : void
IList_NonGeneric_Insert_LastItemToNonNull ( int count ) : void
IList_NonGeneric_Insert_LastItemToNull ( int count ) : void
IList_NonGeneric_Insert_NegativeIndex_ThrowsException ( int count ) : void
IList_NonGeneric_Insert_ToReadOnlyList ( int count ) : void
IList_NonGeneric_IsFixedSize_Validity ( int count ) : void
IList_NonGeneric_IsReadOnly_Validity ( int count ) : void
IList_NonGeneric_ItemGet_IndexGreaterThanListCount_ThrowsException ( int count ) : void
IList_NonGeneric_ItemGet_NegativeIndex_ThrowsException ( int count ) : void
IList_NonGeneric_ItemGet_ValidGetWithinListBounds ( int count ) : void
IList_NonGeneric_ItemSet_DuplicateValues ( int count ) : void
IList_NonGeneric_ItemSet_FirstItemToNonNull ( int count ) : void
IList_NonGeneric_ItemSet_FirstItemToNull ( int count ) : void
IList_NonGeneric_ItemSet_IndexGreaterThanListCount_ThrowsException ( int count ) : void
IList_NonGeneric_ItemSet_InvalidValue ( int count ) : void
IList_NonGeneric_ItemSet_LastItemToNonNull ( int count ) : void
IList_NonGeneric_ItemSet_LastItemToNull ( int count ) : void
IList_NonGeneric_ItemSet_NegativeIndex_ThrowsException ( int count ) : void
IList_NonGeneric_ItemSet_OnReadOnlyList ( int count ) : void
IList_NonGeneric_RemoveAt_AllValidIndices ( int count ) : void
IList_NonGeneric_RemoveAt_IndexGreaterThanListCount_ThrowsException ( int count ) : void
IList_NonGeneric_RemoveAt_NegativeIndex_ThrowsException ( int count ) : void
IList_NonGeneric_RemoveAt_OnReadOnlyList ( int count ) : void
IList_NonGeneric_RemoveAt_ZeroMultipleTimes ( int count ) : void
IList_NonGeneric_Remove_EveryValue ( int count ) : void
IList_NonGeneric_Remove_InvalidValue_ThrowsArgumentException ( int count ) : void
IList_NonGeneric_Remove_NonNullContainedInCollection ( int count ) : void
IList_NonGeneric_Remove_NonNullNotContainedInCollection ( int count ) : void
IList_NonGeneric_Remove_NullContainedInCollection ( int count ) : void
IList_NonGeneric_Remove_NullNotContainedInCollection ( int count ) : void
IList_NonGeneric_Remove_ValueThatExistsTwiceInCollection ( int count ) : void

Method Details

AddToCollection() protected method

protected AddToCollection ( ICollection collection, int numberOfItemsToAdd ) : void
collection ICollection
numberOfItemsToAdd int
return void

AddToCollection() protected method

protected AddToCollection ( IList collection, int numberOfItemsToAdd ) : void
collection IList
numberOfItemsToAdd int
return void

CreateT() protected method

Creates an object that is dependent on the seed given. The object may be either a value type or a reference type, chosen based on the value of the seed.
protected CreateT ( int seed ) : object
seed int
return object

NonGenericICollectionFactory() protected method

protected NonGenericICollectionFactory ( ) : ICollection
return ICollection

NonGenericICollectionFactory() protected method

protected NonGenericICollectionFactory ( int count ) : ICollection
count int
return ICollection

NonGenericIListFactory() protected abstract method

Creates an instance of an IList that can be used for testing.
protected abstract NonGenericIListFactory ( ) : IList
return IList

NonGenericIListFactory() protected method

Creates an instance of an IList that can be used for testing.
protected NonGenericIListFactory ( int count ) : IList
count int The number of unique items that the returned IList contains.
return IList