From: PJ Fanning Date: Fri, 6 Aug 2021 15:22:32 +0000 (+0000) Subject: extend tests X-Git-Tag: REL_5_1_0~85 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=b864503d477b114d00b6f7b078f906a3ccb1f55f;p=poi.git extend tests git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1892042 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/poi/src/test/java/org/apache/poi/ss/formula/functions/TestDateValue.java b/poi/src/test/java/org/apache/poi/ss/formula/functions/TestDateValue.java index 95e518de2b..a36a714d14 100644 --- a/poi/src/test/java/org/apache/poi/ss/formula/functions/TestDateValue.java +++ b/poi/src/test/java/org/apache/poi/ss/formula/functions/TestDateValue.java @@ -74,10 +74,15 @@ final class TestDateValue { // // EXCEL confirmDateValue(new StringEval("8/22/2011"), 40777); // Serial number of a date entered as text. - confirmDateValue(new StringEval("8/22/2011 12:00"), 40777); // Serial number of a date entered as text. confirmDateValue(new StringEval("22-MAY-2011"), 40685); // Serial number of a date entered as text. confirmDateValue(new StringEval("2011/02/23"), 40597); // Serial number of a date entered as text. + //ignore time parts + confirmDateValue(new StringEval("8/22/2011 12:00"), 40777); // Serial number of a date entered as text. + confirmDateValue(new StringEval("8/22/2011 6:02:23 PM"), 40777); // Serial number of a date entered as text. + confirmDateValue(new StringEval("22-AUG-2011 6:02:23PM"), 40777); // Serial number of a date entered as text. + confirmDateValue(new StringEval("22-AUG-2011 6:02:23AM"), 40777); // Serial number of a date entered as text. + // LibreOffice compatibility confirmDateValue(new StringEval("1954-07-20"), 19925); } finally {