diff options
Diffstat (limited to 'tests/exslt/date')
-rw-r--r-- | tests/exslt/date/Makefile.am | 29 | ||||
-rw-r--r-- | tests/exslt/date/Makefile.in | 45 | ||||
-rw-r--r-- | tests/exslt/date/add.1.out | 2 | ||||
-rw-r--r-- | tests/exslt/date/add.1.xml | 1 | ||||
-rw-r--r-- | tests/exslt/date/date.1.out | 10 | ||||
-rw-r--r-- | tests/exslt/date/date.1.xml | 2 | ||||
-rw-r--r-- | tests/exslt/date/datetime.1.out | 14 | ||||
-rw-r--r-- | tests/exslt/date/difference.1.out | 10 | ||||
-rw-r--r-- | tests/exslt/date/difference.1.xml | 3 | ||||
-rw-r--r-- | tests/exslt/date/gyear.1.out | 4 | ||||
-rw-r--r-- | tests/exslt/date/gyear.1.xml | 2 | ||||
-rw-r--r-- | tests/exslt/date/gyearmonth.1.out | 4 | ||||
-rw-r--r-- | tests/exslt/date/gyearmonth.1.xml | 2 | ||||
-rw-r--r-- | tests/exslt/date/seconds.1.out | 6 | ||||
-rw-r--r-- | tests/exslt/date/seconds.1.xml | 2 | ||||
-rw-r--r-- | tests/exslt/date/seconds.2.out | 2 | ||||
-rw-r--r-- | tests/exslt/date/seconds.2.xml | 1 |
17 files changed, 75 insertions, 64 deletions
diff --git a/tests/exslt/date/Makefile.am b/tests/exslt/date/Makefile.am index ec1b896b..515f5496 100644 --- a/tests/exslt/date/Makefile.am +++ b/tests/exslt/date/Makefile.am @@ -38,23 +38,22 @@ CLEANFILES = .memdump test-current: @(echo > .memdump) - @echo \<doc/\> >current.xml - @echo "#" - @echo "# Inspect the following for correctness" - @echo "#" - @(for i in $(srcdir)/current.xsl ; do \ - name=`basename $$i .xsl` ; \ - if [ ! -f $(srcdir)/$$name.xml ] ; then continue ; fi ; \ - $(top_builddir)/xsltproc/xsltproc $(srcdir)/$$name.xsl $(srcdir)/$$name.xml;\ - grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0" || true;\ - done) - @rm -f current.xml + @(if [ -z "$$CONTINUOUS_INTEGRATION" ]; then \ + echo \<doc/\> >current.xml ; \ + echo "#" ; \ + echo "# Inspect the following for correctness" ; \ + echo "#" ; \ + for i in $(srcdir)/current.xsl ; do \ + name=`basename $$i .xsl` ; \ + if [ ! -f $(srcdir)/$$name.xml ] ; then continue ; fi ; \ + $(top_builddir)/xsltproc/xsltproc $(srcdir)/$$name.xsl $(srcdir)/$$name.xml;\ + grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0" || true;\ + done ; \ + rm -f current.xml ; \ + fi) -test-logall: +test tests: $(top_builddir)/xsltproc/xsltproc test-current @echo '## Running exslt date tests' - -test tests: $(top_builddir)/xsltproc/xsltproc test-logall test-current - @echo '## Running exslt common tests' @(echo > .memdump) @(for i in $(srcdir)/*.xsl ; do \ name=`basename $$i .xsl` ; \ diff --git a/tests/exslt/date/Makefile.in b/tests/exslt/date/Makefile.in index e901ea5b..0ae8fcda 100644 --- a/tests/exslt/date/Makefile.in +++ b/tests/exslt/date/Makefile.in @@ -89,7 +89,7 @@ build_triplet = @build@ host_triplet = @host@ subdir = tests/exslt/date ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/configure.in +am__aclocal_m4_deps = $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) @@ -192,7 +192,6 @@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ -MV = @MV@ M_LIBS = @M_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ @@ -209,6 +208,9 @@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PERL = @PERL@ +PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ PYTHON = @PYTHON@ PYTHONSODV = @PYTHONSODV@ PYTHON_INCLUDES = @PYTHON_INCLUDES@ @@ -218,12 +220,10 @@ PYTHON_SUBDIR = @PYTHON_SUBDIR@ PYTHON_VERSION = @PYTHON_VERSION@ RANLIB = @RANLIB@ RELDATE = @RELDATE@ -RM = @RM@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ -TAR = @TAR@ THREAD_LIBS = @THREAD_LIBS@ VERSION = @VERSION@ VERSION_SCRIPT_FLAGS = @VERSION_SCRIPT_FLAGS@ @@ -242,8 +242,6 @@ XSLTPROCDV = @XSLTPROCDV@ XSLT_INCLUDEDIR = @XSLT_INCLUDEDIR@ XSLT_LIBDIR = @XSLT_LIBDIR@ XSLT_LIBS = @XSLT_LIBS@ -XSLT_LOCALE_WINAPI = @XSLT_LOCALE_WINAPI@ -XSLT_LOCALE_XLOCALE = @XSLT_LOCALE_XLOCALE@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ @@ -341,9 +339,9 @@ $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) exit 1;; \ esac; \ done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu tests/exslt/date/Makefile'; \ + echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign tests/exslt/date/Makefile'; \ $(am__cd) $(top_srcdir) && \ - $(AUTOMAKE) --gnu tests/exslt/date/Makefile + $(AUTOMAKE) --foreign tests/exslt/date/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ @@ -527,23 +525,22 @@ $(top_builddir)/xsltproc/xsltproc: test-current: @(echo > .memdump) - @echo \<doc/\> >current.xml - @echo "#" - @echo "# Inspect the following for correctness" - @echo "#" - @(for i in $(srcdir)/current.xsl ; do \ - name=`basename $$i .xsl` ; \ - if [ ! -f $(srcdir)/$$name.xml ] ; then continue ; fi ; \ - $(top_builddir)/xsltproc/xsltproc $(srcdir)/$$name.xsl $(srcdir)/$$name.xml;\ - grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0" || true;\ - done) - @rm -f current.xml - -test-logall: + @(if [ -z "$$CONTINUOUS_INTEGRATION" ]; then \ + echo \<doc/\> >current.xml ; \ + echo "#" ; \ + echo "# Inspect the following for correctness" ; \ + echo "#" ; \ + for i in $(srcdir)/current.xsl ; do \ + name=`basename $$i .xsl` ; \ + if [ ! -f $(srcdir)/$$name.xml ] ; then continue ; fi ; \ + $(top_builddir)/xsltproc/xsltproc $(srcdir)/$$name.xsl $(srcdir)/$$name.xml;\ + grep "MORY ALLO" .memdump | grep -v "MEMORY ALLOCATED : 0" || true;\ + done ; \ + rm -f current.xml ; \ + fi) + +test tests: $(top_builddir)/xsltproc/xsltproc test-current @echo '## Running exslt date tests' - -test tests: $(top_builddir)/xsltproc/xsltproc test-logall test-current - @echo '## Running exslt common tests' @(echo > .memdump) @(for i in $(srcdir)/*.xsl ; do \ name=`basename $$i .xsl` ; \ diff --git a/tests/exslt/date/add.1.out b/tests/exslt/date/add.1.out index 47394ae2..76c18651 100644 --- a/tests/exslt/date/add.1.out +++ b/tests/exslt/date/add.1.out @@ -21,6 +21,8 @@ add : -0001 + -PT59S result : -0002-12-31T23:59:01Z add : -0001 + P1Y result : 0001 +add : -0001-01-01 + P2Y +result : 0002-01-01 add : 2000-01 + -PT86400S result : 1999-12-31 add : 2000-01 + -P1D diff --git a/tests/exslt/date/add.1.xml b/tests/exslt/date/add.1.xml index 5555747e..94cf1ad5 100644 --- a/tests/exslt/date/add.1.xml +++ b/tests/exslt/date/add.1.xml @@ -11,6 +11,7 @@ <date date='2000-01-01T00:00:00Z' dur='-PT59S'/> <date date='-0001' dur='-PT59S'/> <date date='-0001' dur='P1Y'/> + <date date='-0001-01-01' dur='P2Y'/> <date date='2000-01' dur='-PT86400S'/> <date date='2000-01' dur='-P1D'/> <date date='1970-01-01T00:00:00-00:30' dur='-PT30S'/> diff --git a/tests/exslt/date/date.1.out b/tests/exslt/date/date.1.out index f22546c5..8296de53 100644 --- a/tests/exslt/date/date.1.out +++ b/tests/exslt/date/date.1.out @@ -73,8 +73,8 @@ minute-in-hour : NaN second-in-minute : NaN - Test Date : -0004-02-29 - year : -4 + Test Date : -0005-02-29 + year : -5 leap-year : true month-in-year : 2 month-name : February @@ -83,9 +83,9 @@ day-in-year : 60 day-in-month : 29 day-of-week-in-month : 5 - day-in-week : 1 - day-name : Sunday - day-abbreviation : Sun + day-in-week : 5 + day-name : Thursday + day-abbreviation : Thu time : hour-in-day : NaN minute-in-hour : NaN diff --git a/tests/exslt/date/date.1.xml b/tests/exslt/date/date.1.xml index 562e08e8..7f3e9f50 100644 --- a/tests/exslt/date/date.1.xml +++ b/tests/exslt/date/date.1.xml @@ -5,7 +5,7 @@ <date date="3000-01-31"/> <date date="2000-02-29"/> <date date="9990001-12-31Z"/> - <date date="-0004-02-29"/> + <date date="-0005-02-29"/> <date date="1999-01-02"/> <date date="1999-01-03"/> <date date="2004-01-01"/> diff --git a/tests/exslt/date/datetime.1.out b/tests/exslt/date/datetime.1.out index c0b4c537..273130d5 100644 --- a/tests/exslt/date/datetime.1.out +++ b/tests/exslt/date/datetime.1.out @@ -39,12 +39,12 @@ Test Date : -0001-12-31T23:59:59-05:00 year : -1 - leap-year : false + leap-year : true month-in-year : 12 month-name : December month-abbreviation : Dec week-in-year : 52 - day-in-year : 365 + day-in-year : 366 day-in-month : 31 day-of-week-in-month : 5 day-in-week : 1 @@ -75,17 +75,17 @@ Test Date : -10000-12-31T23:59:59Z year : -10000 - leap-year : true + leap-year : false month-in-year : 12 month-name : December month-abbreviation : Dec week-in-year : 1 - day-in-year : 366 + day-in-year : 365 day-in-month : 31 day-of-week-in-month : 5 - day-in-week : 4 - day-name : Wednesday - day-abbreviation : Wed + day-in-week : 2 + day-name : Monday + day-abbreviation : Mon time : 23:59:59Z hour-in-day : 23 minute-in-hour : 59 diff --git a/tests/exslt/date/difference.1.out b/tests/exslt/date/difference.1.out index bcafa2ba..0329e150 100644 --- a/tests/exslt/date/difference.1.out +++ b/tests/exslt/date/difference.1.out @@ -14,7 +14,9 @@ result : -P366D difference : 0002-05-05 - 0001-01 result : -P1Y4M difference : -0002-01-05 - 0001-01-04 -result : P729D +result : P730D +difference : 0002 - -0001 +result : -P2Y difference : 1970-01-01T05:04:03 - 1970-01-01T04:03:02 result : -PT1H1M1S difference : 2000-01-01T05:00:03 - 2000-01-01T04:03:02 @@ -34,4 +36,8 @@ result : -PT2S difference : 2000-01-02T05:00:03 - 2000-01-01T04:03:02 result : -P1DT57M1S difference : 2016-04-28T17:59:30+02:00 - 2016-04-28T17:59:30+04:00 -result : -PT2H
\ No newline at end of file +result : -PT2H +difference : 2000-01-05T01:00:00+11:00 - 2000-01-01T23:00:00-11:00 +result : -P2DT4H +difference : 2000-01-01T23:00:00-11:00 - 2000-01-05T01:00:00+11:00 +result : P2DT4H
\ No newline at end of file diff --git a/tests/exslt/date/difference.1.xml b/tests/exslt/date/difference.1.xml index ca897c09..cfc4759d 100644 --- a/tests/exslt/date/difference.1.xml +++ b/tests/exslt/date/difference.1.xml @@ -9,6 +9,7 @@ <date date1='0002-01-05' date2='0001-01-04'/> <date date1='0002-05-05' date2='0001-01'/> <date date1='-0002-01-05' date2='0001-01-04'/> + <date date1='0002' date2='-0001'/> <date date1='1970-01-01T05:04:03' date2='1970-01-01T04:03:02'/> <date date1='2000-01-01T05:00:03' date2='2000-01-01T04:03:02'/> <date date1='2000-01-01T05:00:03' date2='1980-01-01T04:03:02'/> @@ -23,5 +24,7 @@ <date date1='2000-01-02T05:00:03' date2='2000-01-01T04:03:02'/> <!-- with timezone --> <date date1='2016-04-28T17:59:30+02:00' date2='2016-04-28T17:59:30+04:00'/> + <date date1='2000-01-05T01:00:00+11:00' date2='2000-01-01T23:00:00-11:00'/> + <date date1='2000-01-01T23:00:00-11:00' date2='2000-01-05T01:00:00+11:00'/> </page> diff --git a/tests/exslt/date/gyear.1.out b/tests/exslt/date/gyear.1.out index 9a7b2918..c5c517cd 100644 --- a/tests/exslt/date/gyear.1.out +++ b/tests/exslt/date/gyear.1.out @@ -73,8 +73,8 @@ minute-in-hour : NaN second-in-minute : NaN - Test Date : -0004 - year : -4 + Test Date : -0005 + year : -5 leap-year : true month-in-year : NaN month-name : diff --git a/tests/exslt/date/gyear.1.xml b/tests/exslt/date/gyear.1.xml index 95d776b0..fb1e5771 100644 --- a/tests/exslt/date/gyear.1.xml +++ b/tests/exslt/date/gyear.1.xml @@ -5,6 +5,6 @@ <date date="3000"/>
<date date="2000"/>
<date date="9990001"/>
- <date date="-0004"/>
+ <date date="-0005"/>
</page>
diff --git a/tests/exslt/date/gyearmonth.1.out b/tests/exslt/date/gyearmonth.1.out index 57580c76..6ffef038 100644 --- a/tests/exslt/date/gyearmonth.1.out +++ b/tests/exslt/date/gyearmonth.1.out @@ -73,8 +73,8 @@ minute-in-hour : NaN second-in-minute : NaN - Test Date : -0004-02 - year : -4 + Test Date : -0005-02 + year : -5 leap-year : true month-in-year : 2 month-name : February diff --git a/tests/exslt/date/gyearmonth.1.xml b/tests/exslt/date/gyearmonth.1.xml index 08a7d29b..3e3bdaf4 100644 --- a/tests/exslt/date/gyearmonth.1.xml +++ b/tests/exslt/date/gyearmonth.1.xml @@ -5,6 +5,6 @@ <date date="3000-01"/>
<date date="2000-02"/>
<date date="9990001-12"/>
- <date date="-0004-02"/>
+ <date date="-0005-02"/>
</page>
diff --git a/tests/exslt/date/seconds.1.out b/tests/exslt/date/seconds.1.out index c0eb72c0..9044a312 100644 --- a/tests/exslt/date/seconds.1.out +++ b/tests/exslt/date/seconds.1.out @@ -17,6 +17,10 @@ seconds : -P0Y0M31DT10H10M10.09S result : -2715010.09 seconds : PT100H100M100.001S result : 366100.001 +seconds : PT10H10M.5S +result : 36600.5 +seconds : PT10H10M5.S +result : 36605 seconds : 2001 result : 978307200 seconds : 2001-10-29T10:31:07 @@ -34,7 +38,7 @@ result : 31536000 seconds : 0001-01-01T00:00:00 result : -6.21355968e+10 seconds : -0001-01-01T00:00:00 -result : -6.21671328e+10 +result : -6.21672192e+10 seconds : 1970-01-01 result : 0 seconds : 1970-01-01Z diff --git a/tests/exslt/date/seconds.1.xml b/tests/exslt/date/seconds.1.xml index 24d58fb2..6e33f5c8 100644 --- a/tests/exslt/date/seconds.1.xml +++ b/tests/exslt/date/seconds.1.xml @@ -10,6 +10,8 @@ <date duration="P0Y0M31DT10H10M10.09S"/> <date duration="-P0Y0M31DT10H10M10.09S"/> <date duration="PT100H100M100.001S"/> + <date duration="PT10H10M.5S"/> + <date duration="PT10H10M5.S"/> <!-- date/times --> <date duration="2001"/> <date duration="2001-10-29T10:31:07"/> diff --git a/tests/exslt/date/seconds.2.out b/tests/exslt/date/seconds.2.out index e804d94c..944b7141 100644 --- a/tests/exslt/date/seconds.2.out +++ b/tests/exslt/date/seconds.2.out @@ -7,8 +7,6 @@ seconds : PT-10D result : NaN seconds : --PT10H result : NaN -seconds : PT10H10M.5S -result : NaN seconds : PYT0.00001S result : NaN seconds : PT49.00001 diff --git a/tests/exslt/date/seconds.2.xml b/tests/exslt/date/seconds.2.xml index 276baef7..9052b8f2 100644 --- a/tests/exslt/date/seconds.2.xml +++ b/tests/exslt/date/seconds.2.xml @@ -5,7 +5,6 @@ <date duration="P-T10D"/> <date duration="PT-10D"/> <date duration="--PT10H"/> - <date duration="PT10H10M.5S"/> <date duration="PYT0.00001S"/> <date duration="PT49.00001"/> <date duration="P0Y0MDT10H10M10.09S"/> |