mock(SearchInterface::class); $search->shouldReceive('setLimit')->once(); $search->shouldReceive('parseQuery')->once(); $search->shouldReceive('hasModifiers')->once()->andReturn(false); $search->shouldReceive('getWordsAsString')->once()->andReturn('test'); $search->shouldReceive('searchTransactions')->andReturn(new Collection)->once(); $search->shouldReceive('searchBudgets')->andReturn(new Collection)->once(); $search->shouldReceive('searchTags')->andReturn(new Collection)->once(); $search->shouldReceive('searchCategories')->andReturn(new Collection)->once(); $search->shouldReceive('searchAccounts')->andReturn(new Collection)->once(); $this->be($this->user()); $response = $this->get(route('search.index') . '?q=test'); $response->assertStatus(200); $response->assertSee('