Test Failure – Expected :right now Actual :moments from now

Splash Forums PrettyTime Users Test Failure – Expected :right now Actual :moments from now

This topic contains 4 replies, has 4 voices, and was last updated by  adashrod 5 years, 3 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #18211

    sionsmith
    Participant

    Hello,

    I would like to thank you all for developing this really useful library. However I have spent the best part of a couple of hours trying to figure this problem out:

    When i run the rests (copied from the support page) I get a number ComparisonFailure’s.

    Expected :30 years ago

    Actual :3 decades ago

    Also when using the prettyTime.format(new Date(0)) it seems to give me the complete wrong reference. Could anyone please help / point out what i’m doing wrong?

    Using maven & the latest version.

    Thanks

    #22223

    Hey! Have you tried the 1.0.8-SNAPSHOT version from the OCPsoft repository?

    http://ocpsoft.org/repository/com/ocpsoft/ocpsoft-pretty-time/1.0.8-SNAPSHOT/

    Do you still get the failures there?

    ~Lincoln

    #22224

    Elad
    Participant

    Just tested it on 1.8.0.Final, still happening –

    Log.e(“ELADKATZ”, “Time:”+p.format(new Date(System.currentTimeMillis())));

    prints out 05-07 18:52:36.870: E/ELADKATZ(30596): Time:moments from now

    #22225

    Hmm. That’s bad. Could you please attach a JUnit test case that reproduces this so that I can debug? You can use one of the existing tests as an example: https://github.com/ocpsoft/prettytime

    Thanks!

    ~Lincoln

    #22227

    adashrod
    Participant

    Is there any update on comparing two times that are equal?

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.

Comments are closed.