8.1.1 Filtering the Product List; UNIT TEST: UPDATING EXISTING UNIT TESTS
This commit is contained in:
parent
4b8ce0c014
commit
7659a7b282
@ -31,7 +31,7 @@ namespace SportsStore.UnitTests
|
||||
ProductController controller = new ProductController(mock.Object);
|
||||
controller.PageSize = 3;
|
||||
// Act
|
||||
ProductsListViewModel result = (ProductsListViewModel)controller.List(2).Model;
|
||||
ProductsListViewModel result = (ProductsListViewModel)controller.List(null, 2).Model;
|
||||
// Assert
|
||||
Product[] prodArray = result.Products.ToArray();
|
||||
Assert.IsTrue(prodArray.Length == 2);
|
||||
@ -85,7 +85,7 @@ namespace SportsStore.UnitTests
|
||||
controller.PageSize = 3;
|
||||
|
||||
// Act
|
||||
ProductsListViewModel result = (ProductsListViewModel)controller.List(2).Model;
|
||||
ProductsListViewModel result = (ProductsListViewModel)controller.List(null, 2).Model;
|
||||
|
||||
// Assert
|
||||
PagingInfo pageInfo = result.PagingInfo;
|
||||
|
Loading…
x
Reference in New Issue
Block a user