File tree Expand file tree Collapse file tree 1 file changed +12
-4
lines changed
test/System.Linq.Dynamic.Core.Tests Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Original file line number Diff line number Diff line change 1- using System . Data ;
1+ #if ! NET461
2+ using System . Data ;
23using FluentAssertions ;
34using Xunit ;
45
@@ -95,7 +96,10 @@ public void DynamicGetMemberBinder_SelectOnDataTable()
9596 dataTable . Rows . Add ( "South" , "Apples" , 200 ) ;
9697 dataTable . Rows . Add ( "South" , "Oranges" , 250 ) ;
9798
98- var rows = dataTable . Rows . Cast < DataRow > ( ) . AsQueryable ( ) ;
99+ var extractedRows =
100+ from row in dataTable . AsEnumerable ( )
101+ select row ;
102+ var rows = extractedRows . AsQueryable ( ) ;
99103
100104 // Act
101105 var grouping1 = rows
@@ -127,7 +131,10 @@ public void DynamicGetMemberBinder_SelectTypeOnDataTable()
127131 dataTable . Rows . Add ( "South" , "Apples" , 200 ) ;
128132 dataTable . Rows . Add ( "South" , "Oranges" , 250 ) ;
129133
130- var rows = dataTable . Rows . Cast < DataRow > ( ) . AsQueryable ( ) ;
134+ var extractedRows =
135+ from row in dataTable . AsEnumerable ( )
136+ select row ;
137+ var rows = extractedRows . AsQueryable ( ) ;
131138
132139 // Act
133140 var grouping1 = rows
@@ -168,4 +175,5 @@ public void DynamicGetMemberBinder_SelectOnArrayWithIntegers()
168175 dynamicResult1 . Should ( ) . HaveCount ( 2 ) ;
169176 dynamicResult2 . Should ( ) . BeEquivalentTo ( [ 2 , 4 ] ) ;
170177 }
171- }
178+ }
179+ #endif
You can’t perform that action at this time.
0 commit comments