Passed
Push — master ( a27dd3...975c9f )
by Vladimir
11:24
created

CanCastToString   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
eloc 4
dl 0
loc 13
rs 10
c 1
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 3 1
A __toString() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace GraphQL\Tests\Type\TestClasses;
6
7
class CanCastToString
8
{
9
    /** @var string */
10
    public $str = '';
11
12
    public function __construct($str)
13
    {
14
        $this->str = $str;
15
    }
16
17
    public function __toString()
18
    {
19
        return $this->str;
20
    }
21
}
22