Tests failing for BRT #687

Closed
fcoury opened this Issue Mar 20, 2013 · 3 comments

3 participants

@fcoury

Date.prototype.toString = Wed Mar 20 2013 14:22:04 GMT-0300 (BRT)
Date.prototype.toLocaleString = 3/20/2013 2:22:04 PM
Date.prototype.getTimezoneOffset = 180
navigator.userAgent = Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/537.22 (KHTML, like Gecko) Chrome/25.0.1364.172 Safari/537.22

@timrwood
Moment.js member

Thanks for reporting! Could you post which tests were failing?

@fcoury

Duh, sorry about that :)

month diffs 6 passed,2 failed.
55.1 (-1 === -1) Jan 1 to Feb 1 should be 1 month
55.2 (-0.016129032258064516 === -0.016129032258064516) Jan 1 to Jan 1 noon should be 0.5/31 months
55.3 (-1 === -1) Jan 15 to Feb 15 should be 1 month
55.4 (-1.0013888888888889 === -1) Jan 28 to Feb 28 should be 1 month (true == false)
AssertionError: (-1.0013888888888889 === -1) Jan 28 to Feb 28 should be 1 month
    at Object.ok (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1531:39)
    at equal (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:2729:10)
    at Object.exports.diff.month diffs (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:2863:9)
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1867:16
    at Object.exports.runTest (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1707:9)
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1753:25
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1011:13
    at iterate (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:621:13)
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:632:25
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1013:17
55.5 (-0.9347222222222222 === -0.9333333333333333) Jan 31 to Feb 29 should be 1 - (2/30) months (true == false)
AssertionError: (-0.9347222222222222 === -0.9333333333333333) Jan 31 to Feb 29 should be 1 - (2/30) months
    at Object.ok (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1531:39)
    at equal (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:2729:10)
    at Object.exports.diff.month diffs (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:2864:9)
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1867:16
    at Object.exports.runTest (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1707:9)
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1753:25
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1011:13
    at iterate (http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:621:13)
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:632:25
    at http://momentjs.com/js/tests.js?v=2013-03-07T15:15:04-08:00:1013:17
@ichernev

Duplicate ot #626.

@ichernev ichernev closed this Mar 21, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment