strToDate(): Fix 'order' for just a number <=12
"m" instead of "m y"
This commit is contained in:
parent
70b361ed8b
commit
85bc5d168e
2 changed files with 5 additions and 1 deletions
|
@ -207,6 +207,7 @@ describe("Zotero.Date", function() {
|
|||
var o = Zotero.Date.strToDate('1');
|
||||
assert.equal(o.month, 0);
|
||||
assert.isUndefined(o.year);
|
||||
assert.equal(o.order, 'm');
|
||||
});
|
||||
|
||||
it("should parse string with just day number", function () {
|
||||
|
@ -214,6 +215,7 @@ describe("Zotero.Date", function() {
|
|||
assert.equal(o.day, 25);
|
||||
assert.isUndefined(o.month);
|
||||
assert.isUndefined(o.year);
|
||||
assert.equal(o.order, 'd');
|
||||
});
|
||||
|
||||
it("should work in translator sandbox", function* () {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue