diff --git a/chrome/content/zotero/xpcom/utilities b/chrome/content/zotero/xpcom/utilities index 7ecd907641..dd354a3bf7 160000 --- a/chrome/content/zotero/xpcom/utilities +++ b/chrome/content/zotero/xpcom/utilities @@ -1 +1 @@ -Subproject commit 7ecd907641292bc694f6d775e4d0ab933f157d68 +Subproject commit dd354a3bf76affbe03e3f360b3ad087fdd16c824 diff --git a/test/tests/dateTest.js b/test/tests/dateTest.js index 2147e090c2..41bcf4f853 100644 --- a/test/tests/dateTest.js +++ b/test/tests/dateTest.js @@ -196,6 +196,20 @@ describe("Zotero.Date", function() { assert.notProperty(o, 'year'); }); + it("should parse English month before date", function () { + var o = Zotero.Date.strToDate("June 26, 2010"); + assert.equal(o.month, 5); + assert.equal(o.day, 26); + assert.equal(o.year, 2010); + }); + + it("should parse English month after date", function () { + var o = Zotero.Date.strToDate("26 June 2010"); + assert.equal(o.month, 5); + assert.equal(o.day, 26); + assert.equal(o.year, 2010); + }); + it("should parse Chinese month", function () { Zotero.locale = 'zh-CN'; Zotero.Date.init(); diff --git a/test/tests/feedItemTest.js b/test/tests/feedItemTest.js index 041babb91b..9cb8020e25 100644 --- a/test/tests/feedItemTest.js +++ b/test/tests/feedItemTest.js @@ -93,6 +93,7 @@ describe("Zotero.FeedItem", function () { describe("#fromJSON()", function() { it("should attempt to parse non ISO-8601 dates", function* () { Zotero.locale = 'en-US'; + Zotero.Date.init(); var data = [ { itemType: "journalArticle",