@@ -47,6 +47,7 @@ public void CanExecuteCountWithOrderByArguments()
47
47
public void CanSelectPropertiesIntoObjectArray ( )
48
48
{
49
49
var result = db . Users
50
+ . OrderBy ( u => u . Id )
50
51
. Select ( u => new object [ ] { u . Id , u . Name , u . InvalidLoginAttempts } )
51
52
. First ( ) ;
52
53
@@ -59,6 +60,7 @@ public void CanSelectPropertiesIntoObjectArray()
59
60
public void CanSelectComponentsIntoObjectArray ( )
60
61
{
61
62
var result = db . Users
63
+ . OrderBy ( u => u . Id )
62
64
. Select ( u => new object [ ] { u . Component , u . Component . OtherComponent } )
63
65
. First ( ) ;
64
66
@@ -94,6 +96,7 @@ public void CanSelectConstantsIntoObjectArray()
94
96
const string name = "Julian" ;
95
97
96
98
var result = db . Users
99
+ . OrderBy ( u => u . Id )
97
100
. Select ( u => new object [ ] { u . Id , pi , name , DateTime . MinValue } )
98
101
. First ( ) ;
99
102
@@ -107,6 +110,7 @@ public void CanSelectConstantsIntoObjectArray()
107
110
public void CanSelectPropertiesFromAssociationsIntoObjectArray ( )
108
111
{
109
112
var result = db . Users
113
+ . OrderBy ( u => u . Id )
110
114
. Select ( u => new object [ ] { u . Id , u . Role . Name , u . Role . Entity . Output } )
111
115
. First ( ) ;
112
116
@@ -119,6 +123,7 @@ public void CanSelectPropertiesFromAssociationsIntoObjectArray()
119
123
public void CanSelectPropertiesIntoObjectArrayInProperty ( )
120
124
{
121
125
var result = db . Users
126
+ . OrderBy ( u => u . Id )
122
127
. Select ( u => new { Cells = new object [ ] { u . Id , u . Name , new object [ u . Id ] } } )
123
128
. First ( ) ;
124
129
@@ -132,6 +137,7 @@ public void CanSelectPropertiesIntoObjectArrayInProperty()
132
137
public void CanSelectPropertiesIntoPropertyListInProperty ( )
133
138
{
134
139
var result = db . Users
140
+ . OrderBy ( u => u . Id )
135
141
. Select ( u => new { Cells = new List < object > { u . Id , u . Name , new object [ u . Id ] } } )
136
142
. First ( ) ;
137
143
@@ -144,7 +150,7 @@ public void CanSelectPropertiesIntoPropertyListInProperty()
144
150
[ Test , Description ( "NH-2744" ) ]
145
151
public void CanSelectPropertiesIntoNestedObjectArrays ( )
146
152
{
147
- var query = db . Users . Select ( u => new object [ ] { "Root" , new object [ ] { "Sub1" , u . Name , new object [ ] { "Sub2" , u . Name } } } ) ;
153
+ var query = db . Users . OrderBy ( u => u . Id ) . Select ( u => new object [ ] { "Root" , new object [ ] { "Sub1" , u . Name , new object [ ] { "Sub2" , u . Name } } } ) ;
148
154
var result = query . First ( ) ;
149
155
150
156
Assert . That ( result . Length , Is . EqualTo ( 2 ) ) ;
0 commit comments