Passed
Push — 7.x ( 3ebc9f...4982c4 )
by Adrien
08:52
created

SplIntUnstrictTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 15
Duplicated Lines 0 %

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A test() 0 6 1
1
<?php
2
3
/**
4
 * Part of SplTypes package.
5
 *
6
 * (c) Adrien Loyant <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
declare(strict_types=0);
13
14
namespace Ducks\Component\SplTypes\Tests\phpunit;
15
16
use Ducks\Component\SplTypes\SplInt as DuckInt;
17
use PHPUnit\Framework\TestCase;
18
19
class SplIntUnstrictTest extends TestCase
20
{
21
    /**
22
     * Unit test.
23
     *
24
     * @return void
25
     *
26
     * @psalm-suppress InvalidScalarArgument
27
     */
28
    public function test(): void
29
    {
30
        // @phpstan-ignore-next-line
31
        $instance = new DuckInt(10.0);
32
        $this->assertSame(10, $instance());
33
        unset($instance);
34
    }
35
}
36