@@ -43,6 +43,11 @@ public void Given_Type_When_IsNavigatable_Invoked_Then_It_Should_Return_Result(T
4343
4444 [ DataTestMethod ]
4545 [ DataRow ( typeof ( List < string > ) , true ) ]
46+ [ DataRow ( typeof ( IList < string > ) , true ) ]
47+ [ DataRow ( typeof ( ICollection < string > ) , true ) ]
48+ [ DataRow ( typeof ( IEnumerable < string > ) , true ) ]
49+ [ DataRow ( typeof ( IReadOnlyList < string > ) , true ) ]
50+ [ DataRow ( typeof ( IReadOnlyCollection < string > ) , true ) ]
4651 [ DataRow ( typeof ( int ) , false ) ]
4752 public void Given_Type_When_IsVisitable_Invoked_Then_It_Should_Return_Result ( Type type , bool expected )
4853 {
@@ -53,6 +58,11 @@ public void Given_Type_When_IsVisitable_Invoked_Then_It_Should_Return_Result(Typ
5358
5459 [ DataTestMethod ]
5560 [ DataRow ( typeof ( List < string > ) , true ) ]
61+ [ DataRow ( typeof ( IList < string > ) , true ) ]
62+ [ DataRow ( typeof ( ICollection < string > ) , true ) ]
63+ [ DataRow ( typeof ( IEnumerable < string > ) , true ) ]
64+ [ DataRow ( typeof ( IReadOnlyList < string > ) , true ) ]
65+ [ DataRow ( typeof ( IReadOnlyCollection < string > ) , true ) ]
5666 [ DataRow ( typeof ( int ) , false ) ]
5767 public void Given_Type_When_IsParameterVisitable_Invoked_Then_It_Should_Return_Result ( Type type , bool expected )
5868 {
@@ -63,6 +73,11 @@ public void Given_Type_When_IsParameterVisitable_Invoked_Then_It_Should_Return_R
6373
6474 [ DataTestMethod ]
6575 [ DataRow ( typeof ( List < string > ) , true ) ]
76+ [ DataRow ( typeof ( IList < string > ) , true ) ]
77+ [ DataRow ( typeof ( ICollection < string > ) , true ) ]
78+ [ DataRow ( typeof ( IEnumerable < string > ) , true ) ]
79+ [ DataRow ( typeof ( IReadOnlyList < string > ) , true ) ]
80+ [ DataRow ( typeof ( IReadOnlyCollection < string > ) , true ) ]
6681 [ DataRow ( typeof ( int ) , false ) ]
6782 public void Given_Type_When_IsPayloadVisitable_Invoked_Then_It_Should_Return_Result ( Type type , bool expected )
6883 {
@@ -73,7 +88,17 @@ public void Given_Type_When_IsPayloadVisitable_Invoked_Then_It_Should_Return_Res
7388
7489 [ DataTestMethod ]
7590 [ DataRow ( typeof ( List < string > ) , "array" , null , "string" , false , "string" , 0 ) ]
91+ [ DataRow ( typeof ( IList < string > ) , "array" , null , "string" , false , "string" , 0 ) ]
92+ [ DataRow ( typeof ( ICollection < string > ) , "array" , null , "string" , false , "string" , 0 ) ]
93+ [ DataRow ( typeof ( IEnumerable < string > ) , "array" , null , "string" , false , "string" , 0 ) ]
94+ [ DataRow ( typeof ( IReadOnlyList < string > ) , "array" , null , "string" , false , "string" , 0 ) ]
95+ [ DataRow ( typeof ( IReadOnlyCollection < string > ) , "array" , null , "string" , false , "string" , 0 ) ]
7696 [ DataRow ( typeof ( List < FakeModel > ) , "array" , null , "object" , true , "fakeModel" , 1 ) ]
97+ [ DataRow ( typeof ( IList < FakeModel > ) , "array" , null , "object" , true , "fakeModel" , 1 ) ]
98+ [ DataRow ( typeof ( ICollection < FakeModel > ) , "array" , null , "object" , true , "fakeModel" , 1 ) ]
99+ [ DataRow ( typeof ( IEnumerable < FakeModel > ) , "array" , null , "object" , true , "fakeModel" , 1 ) ]
100+ [ DataRow ( typeof ( IReadOnlyList < FakeModel > ) , "array" , null , "object" , true , "fakeModel" , 1 ) ]
101+ [ DataRow ( typeof ( IReadOnlyCollection < FakeModel > ) , "array" , null , "object" , true , "fakeModel" , 1 ) ]
77102 public void Given_Type_When_Visit_Invoked_Then_It_Should_Return_Result ( Type listType , string dataType , string dataFormat , string itemType , bool isReferential , string referenceId , int expected )
78103 {
79104 var name = "hello" ;
@@ -118,7 +143,17 @@ public void Given_Attribute_When_Visit_Invoked_Then_It_Should_Return_Result(Open
118143
119144 [ DataTestMethod ]
120145 [ DataRow ( typeof ( List < string > ) , "array" , null , "string" , false ) ]
146+ [ DataRow ( typeof ( IList < string > ) , "array" , null , "string" , false ) ]
147+ [ DataRow ( typeof ( ICollection < string > ) , "array" , null , "string" , false ) ]
148+ [ DataRow ( typeof ( IEnumerable < string > ) , "array" , null , "string" , false ) ]
149+ [ DataRow ( typeof ( IReadOnlyList < string > ) , "array" , null , "string" , false ) ]
150+ [ DataRow ( typeof ( IReadOnlyCollection < string > ) , "array" , null , "string" , false ) ]
121151 [ DataRow ( typeof ( List < FakeModel > ) , "array" , null , "object" , true ) ]
152+ [ DataRow ( typeof ( IList < FakeModel > ) , "array" , null , "object" , true ) ]
153+ [ DataRow ( typeof ( ICollection < FakeModel > ) , "array" , null , "object" , true ) ]
154+ [ DataRow ( typeof ( IEnumerable < FakeModel > ) , "array" , null , "object" , true ) ]
155+ [ DataRow ( typeof ( IReadOnlyList < FakeModel > ) , "array" , null , "object" , true ) ]
156+ [ DataRow ( typeof ( IReadOnlyCollection < FakeModel > ) , "array" , null , "object" , true ) ]
122157 public void Given_Type_When_ParameterVisit_Invoked_Then_It_Should_Return_Result ( Type listType , string dataType , string dataFormat , string itemType , bool isItemToBeNull )
123158 {
124159 var result = this . _visitor . ParameterVisit ( listType , this . _strategy ) ;
@@ -135,7 +170,17 @@ public void Given_Type_When_ParameterVisit_Invoked_Then_It_Should_Return_Result(
135170
136171 [ DataTestMethod ]
137172 [ DataRow ( typeof ( List < string > ) , "array" , null , "string" , "string" ) ]
173+ [ DataRow ( typeof ( IList < string > ) , "array" , null , "string" , "string" ) ]
174+ [ DataRow ( typeof ( ICollection < string > ) , "array" , null , "string" , "string" ) ]
175+ [ DataRow ( typeof ( IEnumerable < string > ) , "array" , null , "string" , "string" ) ]
176+ [ DataRow ( typeof ( IReadOnlyList < string > ) , "array" , null , "string" , "string" ) ]
177+ [ DataRow ( typeof ( IReadOnlyCollection < string > ) , "array" , null , "string" , "string" ) ]
138178 [ DataRow ( typeof ( List < FakeModel > ) , "array" , null , "object" , "fakeModel" ) ]
179+ [ DataRow ( typeof ( IList < FakeModel > ) , "array" , null , "object" , "fakeModel" ) ]
180+ [ DataRow ( typeof ( ICollection < FakeModel > ) , "array" , null , "object" , "fakeModel" ) ]
181+ [ DataRow ( typeof ( IEnumerable < FakeModel > ) , "array" , null , "object" , "fakeModel" ) ]
182+ [ DataRow ( typeof ( IReadOnlyList < FakeModel > ) , "array" , null , "object" , "fakeModel" ) ]
183+ [ DataRow ( typeof ( IReadOnlyCollection < FakeModel > ) , "array" , null , "object" , "fakeModel" ) ]
139184 public void Given_Type_When_PayloadVisit_Invoked_Then_It_Should_Return_Result ( Type listType , string dataType , string dataFormat , string itemType , string referenceId )
140185 {
141186 var result = this . _visitor . PayloadVisit ( listType , this . _strategy ) ;
0 commit comments