[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] gnash ChangeLog testsuite/actionscript.all/Date.as
From: |
Benjamin Wolsey |
Subject: |
[Gnash-commit] gnash ChangeLog testsuite/actionscript.all/Date.as |
Date: |
Mon, 31 Mar 2008 15:38:14 +0000 |
CVSROOT: /sources/gnash
Module name: gnash
Changes by: Benjamin Wolsey <bwy> 08/03/31 15:38:14
Modified files:
. : ChangeLog
testsuite/actionscript.all: Date.as
Log message:
more date tests.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.6120&r2=1.6121
http://cvs.savannah.gnu.org/viewcvs/gnash/testsuite/actionscript.all/Date.as?cvsroot=gnash&r1=1.43&r2=1.44
Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.6120
retrieving revision 1.6121
diff -u -b -r1.6120 -r1.6121
--- ChangeLog 31 Mar 2008 15:09:37 -0000 1.6120
+++ ChangeLog 31 Mar 2008 15:38:14 -0000 1.6121
@@ -1,5 +1,9 @@
2008-03-31 Benjamin Wolsey <address@hidden>
+ * testsuite/actionscript.all/Date.as: more tests.
+
+2008-03-31 Benjamin Wolsey <address@hidden>
+
* testsuite/actionscript.all/Date.as: fix expected results.
Some aren't the same as the pp - there was already a note about
that, and maybe it is worth emulating the player here.
Index: testsuite/actionscript.all/Date.as
===================================================================
RCS file: /sources/gnash/gnash/testsuite/actionscript.all/Date.as,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -b -r1.43 -r1.44
--- testsuite/actionscript.all/Date.as 31 Mar 2008 15:09:38 -0000 1.43
+++ testsuite/actionscript.all/Date.as 31 Mar 2008 15:38:14 -0000 1.44
@@ -22,7 +22,7 @@
// execute it like this gnash -1 -r 0 -v out.swf
-rcsid="$Id: Date.as,v 1.43 2008/03/31 15:09:38 bwy Exp $";
+rcsid="$Id: Date.as,v 1.44 2008/03/31 15:38:14 bwy Exp $";
#include "check.as"
check_equals(typeof(Date), 'function');
@@ -603,7 +603,7 @@
d.setMonth(11);
check_equals (d.getHours(), 0);
-// It's not easy to test the toString() code here cos we cannot find out from
+// It's not easy to test the toString() code here because we cannot find out
from
// within AS whether DST is in effect or not.
check_equals (Date.UTC(1970,0), 0);
@@ -619,6 +619,22 @@
check (Date.UTC(2000,6,1,0,0,0,0) == d.valueOf());
+xcheck_equals (Date.UTC(-1000, 20).valueOf(), -33713366400000);
+xcheck_equals (Date.UTC(-70, 0).toString(), "-4417977600000");
+xcheck_equals (Date.UTC(-70, 0).valueOf(), -4417977600000);
+check_equals (Date.UTC(1969, 11).toString(), "-2678400000");
+check_equals (Date.UTC(1969, 11).valueOf(), -2678400000);
+check_equals (Date.UTC(1969, 12).toString(), "0");
+check_equals (Date.UTC(1969, 12).valueOf(), 0);
+check_equals (Date.UTC(0, 0, 0, 0, 0, 0, 0).tostring(), "-2209075200000");
+check_equals (Date.UTC(1969, 12, 31).tostring(), "2592000000");
+check_equals (Date.UTC(1969, 12, 31).tostring(), "2592000000");
+check_equals (Date.UTC(1970, 1).toString(), "2678400000");
+check_equals (Date.UTC(1970, 1).valueOf(), 2678400000);
+
+xcheck_equals (Date.UTC(-1, -12).toString(), "-2272060800000");
+xcheck_equals (Date.UTC(-1, 12).valueOf(), -2208988800000);
+
// Check if Date, concatenated to a string, is in human readable form
d = new Date(2000, 1, 15, 0, 0, 0);
var foo = "foo "+d;
@@ -641,7 +657,7 @@
#endif
#if OUTPUT_VERSION == 5
-totals(274);
+totals(288);
#else
-totals (316);
+totals (330);
#endif