Skip to content

How to test transitions/animations? #12120

Closed

Description

@emilio

As animation support increases, it'd be great to have some sort of testing support for it.

We can't test them deteministically right now. Gecko has a "test mode" in their refresh driver that allows them to fake the times, advance the clocks, etc. as well as an API to get the computed style for an element in a given point of time.

We don't have that infra, and though it seems like a good amount of work, I think it's worth doing.

Activity

  1. added
    A-content/css
    on Jul 1, 2016
  2. emilio commented on Jul 7, 2016

    @emilio
    MemberAuthor

    So the idea I'm thinking about is adding a pref or something as we do to test our crash handler, but adding:

    1. A test mode to the constellation that allows us to trigger animation ticks on-demand.
    2. A pref-guarded API that allows us to "move" the clock by a delta, and trigger an animation tick.

    I think that should be enough to be able to write a bunch of animation tests under tests/mozilla.

    CC'ing @Ms2ger and @jdm just in case they have thoughts on this or maybe a better way to do it :)

  3. jdm commented on Jul 7, 2016

    @jdm
    Member

    No better idea!

  4. metajack commented on Jul 8, 2016

    @metajack
    Collaborator

    👍

  5. emilio commented on Jul 11, 2016

    @emilio
    MemberAuthor

    A potential implementation of this lives in #12392

  6. added a commit that references this issue on Jul 20, 2016
    14aeccc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-content/cssA-testing

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions