Open pouyamn opened 5 years ago
the test fails in cloning:
1) moment
#clone clone of an invalid date is invalid: AssertionError: expected true to equal false + expected - actual -true +false at Context.<anonymous> (test.js:9:46665)
2) moment
clone should not affect on calendar system
instance locale and clone: AssertionError: expected '1989/01/23' to equal '1367/11/03' + expected - actual -1989/01/23 +1367/11/03
I don't know why it's happening, the problem with current code is that it destroies the input's config, if one uses a library which adds something to moment config through momentJS plugin system, the added context should be kept during cloning. An example of these libraries is full-calendar.js
Have anyone got any Ideas?
moment constructor do accept arrays and moment objects as input, so should jMoment