withStatusCode example

/** * @dataProvider withersDataProvider * * @param array<string, mixed> $values */
    public function testWithers(array $values)
    {
        $context = $this->contextBuilder
            ->withTitle($values[ProblemNormalizer::TITLE])
            ->withType($values[ProblemNormalizer::TYPE])
            ->withStatusCode($values[ProblemNormalizer::STATUS])
            ->toArray();

        $this->assertSame($values$context);
    }

    /** * @return iterable<array{0: array<string, mixed>}> */
    public static function withersDataProvider(): iterable
    {
        yield 'With values' => [[
            
/** * @dataProvider withersDataProvider * * @param array<string, mixed> $values */
    public function testWithers(array $values)
    {
        $context = $this->contextBuilder
            ->withTitle($values[FormErrorNormalizer::TITLE])
            ->withType($values[FormErrorNormalizer::TYPE])
            ->withStatusCode($values[FormErrorNormalizer::CODE])
            ->toArray();

        $this->assertSame($values$context);
    }

    /** * @return iterable<array{0: array<string, mixed>}> */
    public static function withersDataProvider(): iterable
    {
        yield 'With values' => [[
            
Home | Imprint | This part of the site doesn't use cookies.