Skip to content

Date.create is undefined  #427

@maca

Description

@maca

Either by making a build with only core, date and formats and by importing sugar-full.min.js, the create method for Date is not defined, I am interested in the natural language date parsing

Date.create
undefined

--EDIT

Using sinon fakeTimers restores Date methods and deletes Date.create, following code will break Date.create:

  it('should be past due if due has passed', function(){
    clock = sinon.useFakeTimers(new Date(2014,1,1).getTime());
    expect( task.is_past_due ).to.eq(false)
    clock = sinon.useFakeTimers(new Date(2015,1,1).getTime());
    expect( task.is_past_due ).to.eq(true)
    clock.restore();
  });

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions