mirror of
https://github.com/PHPOffice/PhpSpreadsheet.git
synced 2026-08-30 20:18:00 +00:00
Statistical issues (#1098)
* Merge branch 'master' of C:\Projects\PHPOffice\PHPSpreadsheet\develop with conflicts. * Adjusted logic for COUNT() function to handle differences in EXCEL, GNUMERIC and OPENOFFICE modes for cells and for literal values * Fix case-sensitivity in filenames * Appeasing Codesniffer * Resolve COUNTA() differences between cell values and literals * Style fixes * Start refactoring statistical function tests into individual tests rather than having a single, giant test for all statistical functions.... first step toward doing this for all tests * More refactoring into separate tests If all functions have their own individual test files, it should be a lot easier to identify which functions aren't covered by tests yet * Missing last lines in files
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
namespace PhpOffice\PhpSpreadsheetTests\Calculation\Functions\Statistical;
|
||||
|
||||
use PhpOffice\PhpSpreadsheet\Calculation\Functions;
|
||||
use PhpOffice\PhpSpreadsheet\Calculation\Statistical;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class BetaDistTest extends TestCase
|
||||
{
|
||||
public function setUp()
|
||||
{
|
||||
Functions::setCompatibilityMode(Functions::COMPATIBILITY_EXCEL);
|
||||
}
|
||||
|
||||
/**
|
||||
* @dataProvider providerBETADIST
|
||||
*
|
||||
* @param mixed $expectedResult
|
||||
*/
|
||||
public function testBETADIST($expectedResult, ...$args)
|
||||
{
|
||||
$result = Statistical::BETADIST(...$args);
|
||||
self::assertEquals($expectedResult, $result, '', 1E-12);
|
||||
}
|
||||
|
||||
public function providerBETADIST()
|
||||
{
|
||||
return require 'data/Calculation/Statistical/BETADIST.php';
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user