protected override void Given()
        {
            Dependency<IPageRepository>()
                .Stub(x => x.Query("query"))
                .Return(pageResources);

            resource = new SearchResultsResource {Query = "query"};
        }
 protected override void When()
 {
     result = Subject<SearchHandler>().Get(resource);
 }
示例#3
0
 public SearchResultsResource Get(SearchResultsResource resource)
 {
     resource.PageResources = pageRepository.Query(resource.Query);
     return resource;
 }