Date should use historical data if it's available.
authorkeith_miller@apple.com <keith_miller@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 26 May 2017 00:06:44 +0000 (00:06 +0000)
committerkeith_miller@apple.com <keith_miller@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 26 May 2017 00:06:44 +0000 (00:06 +0000)
commit928c6241a8ad052b2a1add579632634ac09d5c9e
treefebe834cf6721695429407935ddc11d42952b502
parent3be202f3a314fe67ace9923e556dc57bdd9d727b
Date should use historical data if it's available.
https://bugs.webkit.org/show_bug.cgi?id=172592

Reviewed by Mark Lam.

JSTests:

Remove parts of the date tests that rely on the absence of
historical data in Date.

* mozilla/ecma/Date/15.9.5.31-1.js:
(getTestCases):
* mozilla/ecma/Date/15.9.5.35-1.js:
(getTestCases):

Source/WTF:

The spec previously disallowed using historical data for Dates.
This is no longer the case. Additionally, not using historical
data, when available, seems unfortunate for users. This patch
removes the code dropping historical data.

* wtf/DateMath.cpp:
(WTF::calculateLocalTimeOffset):
(WTF::msToMilliseconds): Deleted.

LayoutTests:

Fix tests to work with historically accurate dates.

* js/dom/date-big-setdate-expected.txt: Removed.
* js/dom/date-big-setdate.html: Removed.
* js/dom/script-tests/date-big-setdate.js: Removed.
* storage/indexeddb/modern/date-basic-expected.txt:
* storage/indexeddb/modern/date-basic-private-expected.txt:
* storage/indexeddb/modern/get-keyrange-expected.txt:
* storage/indexeddb/modern/get-keyrange-private-expected.txt:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@217458 268f45cc-cd09-0410-ab3c-d52691b4dbfc
13 files changed:
JSTests/ChangeLog
JSTests/mozilla/ecma/Date/15.9.5.31-1.js
JSTests/mozilla/ecma/Date/15.9.5.35-1.js
LayoutTests/ChangeLog
LayoutTests/js/dom/date-big-setdate-expected.txt [deleted file]
LayoutTests/js/dom/date-big-setdate.html [deleted file]
LayoutTests/js/dom/script-tests/date-big-setdate.js [deleted file]
LayoutTests/storage/indexeddb/modern/date-basic-expected.txt
LayoutTests/storage/indexeddb/modern/date-basic-private-expected.txt
LayoutTests/storage/indexeddb/modern/get-keyrange-expected.txt
LayoutTests/storage/indexeddb/modern/get-keyrange-private-expected.txt
Source/WTF/ChangeLog
Source/WTF/wtf/DateMath.cpp