RatingListingFilterHandler example

use Symfony\Component\HttpFoundation\Request;

/** * @internal * * @covers \Shopware\Core\Content\Product\SalesChannel\Listing\Filter\RatingListingFilterHandler */
class RatingFilterHandlerTest extends TestCase
{
    public function testFilterCanBeSkipped(): void
    {
        $result = (new RatingListingFilterHandler())->create(
            new Request([]['rating-filter' => false]),
            $this->createMock(SalesChannelContext::class)
        );

        static::assertNull($result);
    }

    /** * @dataProvider filterProvider */
    public function testFilterCanBeCreated(int $input): void
    {
Home | Imprint | This part of the site doesn't use cookies.