PhpSpreadsheet/tests/PhpSpreadsheetTests/Calculation/Functions/Engineering/Dec2OctTest.php

32 lines
786 B
PHP
Raw Normal View History

<?php
namespace PhpOffice\PhpSpreadsheetTests\Calculation\Functions\Engineering;
use PhpOffice\PhpSpreadsheet\Calculation\Engineering;
use PhpOffice\PhpSpreadsheet\Calculation\Functions;
use PHPUnit\Framework\TestCase;
class Dec2OctTest extends TestCase
{
2020-04-27 10:28:36 +00:00
protected function setUp(): void
{
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
}
/**
* @dataProvider providerDEC2OCT
*
* @param mixed $expectedResult
*/
2020-05-18 04:49:57 +00:00
public function testDEC2OCT($expectedResult, ...$args): void
{
$result = Engineering::DECTOOCT(...$args);
2020-05-18 04:49:57 +00:00
self::assertEquals($expectedResult, $result);
}
public function providerDEC2OCT()
{
return require 'tests/data/Calculation/Engineering/DEC2OCT.php';
}
}