Passed
Pull Request — master (#38)
by Andrey
03:26
created

EnumValue::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
cc 1
eloc 1
c 0
b 0
f 0
nc 1
nop 3
dl 0
loc 6
ccs 2
cts 2
cp 1
crap 1
rs 10
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Andi\GraphQL\Attribute;
6
7
use Attribute;
8
use Spiral\Attributes\NamedArgumentConstructor;
9
10
#[Attribute(Attribute::TARGET_CLASS_CONSTANT), NamedArgumentConstructor]
11
final class EnumValue extends AbstractDefinition
12
{
13 2
    public function __construct(
14
        ?string $name = null,
15
        ?string $description = null,
16
        public readonly ?string $deprecationReason = null,
17
    ) {
18 2
        parent::__construct($name, $description);
19
    }
20
}
21