Completed
Push — master ( c4895b...a6c56d )
by Adrien
31:05 queued 25:18
created

FloorPreciseTest   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 5
dl 0
loc 21
rs 10
c 1
b 0
f 0
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A testFLOOR() 0 4 1
A setUp() 0 3 1
A providerFLOORPRECISE() 0 3 1
1
<?php
2
3
namespace PhpOffice\PhpSpreadsheetTests\Calculation\Functions\MathTrig;
4
5
use PhpOffice\PhpSpreadsheet\Calculation\Functions;
6
use PhpOffice\PhpSpreadsheet\Calculation\MathTrig;
7
use PHPUnit\Framework\TestCase;
8
9
class FloorPreciseTest extends TestCase
10
{
11
    public function setUp()
12
    {
13
        Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
14
    }
15
16
    /**
17
     * @dataProvider providerFLOORPRECISE
18
     *
19
     * @param mixed $expectedResult
20
     */
21
    public function testFLOOR($expectedResult, ...$args)
22
    {
23
        $result = MathTrig::FLOORPRECISE(...$args);
1 ignored issue
show
Bug introduced by
$args is expanded, but the parameter $number of PhpOffice\PhpSpreadsheet...athTrig::FLOORPRECISE() does not expect variable arguments. ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-type  annotation

23
        $result = MathTrig::FLOORPRECISE(/** @scrutinizer ignore-type */ ...$args);
Loading history...
24
        $this->assertEquals($expectedResult, $result, '', 1E-12);
25
    }
26
27
    public function providerFLOORPRECISE()
28
    {
29
        return require 'data/Calculation/MathTrig/FLOORPRECISE.php';
30
    }
31
}
32