Completed
Pull Request — master (#20)
by Anatoliy
29:38 queued 19:40
created

DoubleTypeMock::getSample()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 5
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 3
nc 1
nop 0
1
<?php
2
declare(strict_types=1);
3
/**
4
 * Created by PhpStorm.
5
 * User: danchukas
6
 * Date: 2017-07-18 08:46
7
 */
8
9
namespace DanchukAS\Mock\Type;
10
11
12
use DanchukAS\Mock\TypeMock;
13
14
/**
15
 * Class DoubleTypeMock
16
 * @package DanchukAS\Mock\Type
17
 */
18
class DoubleTypeMock extends TypeMock
19
{
20
    protected static $optimalCount = 3;
21
22
    /**
23
     * @return float|\Generator
24
     */
25
    public static function getSample()
26
    {
27
        yield ["double(big)" => PHP_INT_MAX / 0.3];
28
        yield ["double(small)" => PHP_INT_MIN / 0.9];
0 ignored issues
show
Bug introduced by
The constant DanchukAS\Mock\Type\PHP_INT_MIN was not found. Maybe you did not declare it correctly or list all dependencies?
Loading history...
29
        yield ["double(near zerro)" => -1.0 / 3.0];
30
    }
31
}