public function searchAllContentTypes(array $parameters = [], &$pager = []) { // Note: we can only apply this kind of results aggregating when we don't // use LIMIT and OFFSET! If we'd want to use it, this should be rewritten. // Results aggregator $result = []; foreach ($this->getContentTypes() as $contenttype) { $contentTypeSearchResults = $this->searchContentType($contenttype, $parameters, $pager); foreach ($contentTypeSearchResults as $searchresult) { $result[] = $searchresult; } } return $result; }
public function testSearchAllContentTypes() { $app = $this->getApp(); $app['request'] = Request::create('/'); $storage = new Storage($app); $results = $storage->searchAllContentTypes(['title' => 'lorem']); }