diff --git a/src/Foundation/Tests/ProductSearchTest.php b/src/Foundation/Tests/ProductSearchTest.php index 6087be9c6..0ef77f7d4 100644 --- a/src/Foundation/Tests/ProductSearchTest.php +++ b/src/Foundation/Tests/ProductSearchTest.php @@ -509,9 +509,8 @@ public function it_can_limit_the_number_of_results() factory(Product::class, 4)->create(); factory(MasterProduct::class, 3)->create(); - $finder = new ProductSearch(); - $this->assertCount(7, $finder->getResults()); - $this->assertCount(5, $finder->getResults(5)); + $this->assertCount(7, (new ProductSearch())->getResults()); + $this->assertCount(5, (new ProductSearch())->getResults(5)); } /** @test */