public void SetUp() { mCategoryServiceMock = A.Fake<ICategoryService>(); mAuctionServiceMock = A.Fake<IAuctionService>(); mBreadcrumbBuilderMock = A.Fake<IBreadcrumbBuilder>(); mRequestMock = A.Fake<HttpRequestBase>(); mResponseMock = A.Fake<HttpResponseBase>(); mTestedController = new CategoryController(mCategoryServiceMock, mAuctionServiceMock, mBreadcrumbBuilderMock, mRequestMock, mResponseMock); var fakePagedList = A.Fake<IPagedList<Auction>>(); A.CallTo(() => fakePagedList.PageNumber).Returns(1); A.CallTo(() => fakePagedList.PageSize).Returns(1); A.CallTo(() => mAuctionServiceMock.GetActiveAuctionsInCategory(0, null, 0, 0, 0)).WithAnyArguments().Returns(fakePagedList); }