File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -31,11 +31,20 @@ public void TestUseEnumerable()
3131 {
3232 Filler < EntityCollection > eFiller = new Filler < EntityCollection > ( ) ;
3333 eFiller . Setup ( )
34- . OnProperty ( x => x . EntityArray ) . IgnoreIt ( )
34+ . ListItemCount ( 20 )
35+ . OnProperty ( x => x . EntityArray , x => x . EntityICollection ,
36+ x => x . EntityIList , x => x . ObservableCollection ,
37+ x => x . EntityIEnumerable ) . IgnoreIt ( )
3538 . SetupFor < Entity > ( )
36- . OnProperty ( x => x . Id ) . Use ( Enumerable . Range ( 1 , 100 ) . Select ( x => ( int ) Math . Pow ( 2 , x ) ) ) ;
39+ . OnProperty ( x => x . Id ) . Use ( Enumerable . Range ( 1 , 22 ) . Select ( x => ( int ) Math . Pow ( 2 , x ) ) ) ;
3740
3841 EntityCollection ec = eFiller . Create ( ) ;
42+
43+ for ( int i = 0 ; i < ec . EntityList . Count ; i ++ )
44+ {
45+ int lastPowNum = ( int ) Math . Pow ( 2 , i + 1 ) ;
46+ Assert . AreEqual ( lastPowNum , ec . EntityList [ i ] . Id ) ;
47+ }
3948 }
4049
4150 [ TestMethod ]
You can’t perform that action at this time.
0 commit comments