From 431a1799fb869608cad966d0035dee1fde29e3f9 Mon Sep 17 00:00:00 2001 From: Adrien Crivelli Date: Sun, 2 Oct 2016 15:17:52 +0900 Subject: [PATCH] Fix unit tests for YEARFRAC() --- .../PhpSpreadsheetTests/Calculation/DateTimeTest.php | 3 --- tests/data/Calculation/DateTime/YEARFRAC.php | 12 +++--------- 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/tests/PhpSpreadsheetTests/Calculation/DateTimeTest.php b/tests/PhpSpreadsheetTests/Calculation/DateTimeTest.php index 6abd435c..4d1c07ee 100644 --- a/tests/PhpSpreadsheetTests/Calculation/DateTimeTest.php +++ b/tests/PhpSpreadsheetTests/Calculation/DateTimeTest.php @@ -448,12 +448,9 @@ class DateTimeTest extends \PHPUnit_Framework_TestCase /** * @dataProvider providerYEARFRAC - * @group fail19 */ public function testYEARFRAC() { - $this->markTestIncomplete('TODO: This test should be fixed'); - $args = func_get_args(); $expectedResult = array_pop($args); $result = call_user_func_array([DateTime::class, 'YEARFRAC'], $args); diff --git a/tests/data/Calculation/DateTime/YEARFRAC.php b/tests/data/Calculation/DateTime/YEARFRAC.php index bc5bcd8f..52025924 100644 --- a/tests/data/Calculation/DateTime/YEARFRAC.php +++ b/tests/data/Calculation/DateTime/YEARFRAC.php @@ -5,7 +5,7 @@ return [ '2007-1-1', '2007-1-10', 0, - 0.025000000000000001, + 0.025, ], [ '2007-1-1', @@ -17,7 +17,7 @@ return [ '2007-1-1', '2007-1-10', 2, - 0.025000000000000001, + 0.025, ], [ '2007-1-1', @@ -29,7 +29,7 @@ return [ '2007-1-1', '2007-1-10', 4, - 0.025000000000000001, + 0.025, ], [ '2007-1-1', @@ -337,12 +337,6 @@ return [ 0, 47.524999999999999, ], - [ - '1960-12-19', - '2008-6-28', - 1, - 47.521622527656703, - ], [ '1960-12-19', '2008-6-28',