#527 ✓ staged
cadecairos

Subtitle unit tests #2 and #7 Fail sometimes

Reported by cadecairos | May 17th, 2011 @ 03:53 PM | in 0.6

When you run the subtitle unit tests, they fail sometimes, if not every time in FF 4.

Comments and changes to this ticket

  • cadecairos

    cadecairos May 18th, 2011 @ 09:52 AM

    • State changed from “new” to “peer-review-requested”

    I wrote a fix for this. The problem was that the code in the test which changed styles for the subtitle and video would take longer than 0.5 seconds to execute, so when the equals() ran, the subtitle contents had been modified.

    here is the commit

  • Rick

    Rick May 18th, 2011 @ 10:04 AM

    • State changed from “peer-review-requested” to “super-review-requested”
    • Milestone changed from 0.7 to 0.6
    • Assigned user set to “annasob”
    • Milestone order changed from “35” to “0”

    I want to land this in 0.6

    Tested: subtitle test suite;

    Passing in:

    • FF 3.6, 4.x, 6.x

    • Chrome 11, 12, 13

    Failing in:

    • none
  • Scott Downe

    Scott Downe May 18th, 2011 @ 10:16 AM

    • Milestone changed from 0.6 to 0.7
    • State changed from “super-review-requested” to “peer-review-requested”
    • Assigned user cleared.
    • Milestone order changed from “1” to “0”

    Another solution would of been video.pause() and video.play() wrapping the inside of the exec, just to be sure.

  • Scott Downe

    Scott Downe May 18th, 2011 @ 10:17 AM

    • Milestone changed from 0.7 to 0.6
    • State changed from “peer-review-requested” to “super-review-requested”
    • Assigned user set to “annasob”
    • Milestone order changed from “35” to “0”

    Opps. Comment conflict.

  • Scott Downe

    Scott Downe May 18th, 2011 @ 10:52 AM

    • State changed from “super-review-requested” to “review-looks-good”

    OK, I'm fine with this as well. If we have any problems in the future in this or another test, I'll explore pausing and starting the video more.

  • cadecairos

    cadecairos May 18th, 2011 @ 11:12 AM

    I'm getting random failures on chrome and firefox on Windows.... going to implement the pause - play idea.

  • Scott Downe

    Scott Downe May 18th, 2011 @ 11:14 AM

    • State changed from “review-looks-good” to “review-needs-work”
  • cadecairos

    cadecairos May 18th, 2011 @ 11:25 AM

    • State changed from “review-needs-work” to “peer-review-requested”

    So adding pause() and play() to the start/finish of each exec call stops tests from failing randomly in Firefox 4, but they still fail at random in Chrome 11... can anyone confirm this behaviour?

    commit

  • cadecairos

    cadecairos May 18th, 2011 @ 11:26 AM

    forgot to mention that it only fails in Chrome 11 on Windows 7

  • Scott Downe

    Scott Downe May 18th, 2011 @ 12:22 PM

    The pause fixes it in FF, which means the race condition is fixed.

    You added a nice WIDE range to the test, yet chrome still from time to time has a problem. I think this is something else. You have a range of 1.5, and yet, it's still not enough.

    Also, I'm not a fan of these wide ranges. Fast tests are good :)

  • Scott Downe

    Scott Downe May 18th, 2011 @ 12:32 PM

    Try this and see if you can make this error out: http://pastebin.com/RAWf7iQd

  • cadecairos

    cadecairos May 18th, 2011 @ 12:38 PM

    should be working now..

    commit

    branch is subtitle

  • Scott Downe

    Scott Downe May 18th, 2011 @ 12:40 PM

    • State changed from “peer-review-requested” to “review-looks-good”

    Yeah, I can confirm I cannot make these fail anymore. Both Chrome and FF passing.

    This was already r+, so I am sr+

  • annasob

    annasob May 18th, 2011 @ 01:54 PM

    • State changed from “review-looks-good” to “staged”

    Staged in annasob/popcorn-js commit

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

Popcorn.js is an HTML5 video framework that lets you bring elements of the web into your videos.

Popcorn.js is a project of Web Made Movies, Mozilla's Open Video Lab.

Shared Ticket Bins

Pages