Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit aea2a174 authored by Jeff Sharkey's avatar Jeff Sharkey
Browse files

Defer AnimatorTestRule Handler until used by tests.

As part of supporting SysUI multivalentTests under the new Ravenwood
testing environment, tests need to be more careful about only
creating and interacting with "complex" objects when they're actually
needed by a test.  Attempting interactions during <init> or <clinit>
of the overall test class fails on Ravenwood when these complex
objects aren't yet supported, and they throw an exception.

This change focuses on `AnimatorTestRule`, which attempts to
unconditionally create an `AnimationHandler` internally; it migrates
the actual creation to become lazy via a `Singleton` pattern, so that
we only construct it when actually needed by a test.

Bug: 319647875
Test: atest SystemUiRoboTests
Change-Id: Iec1c2d63062466527688e929b66f01631511f47a
parent ff93fc40
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment