-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
org.robolectric.util.Scheduler should use java.time APIs #8976
Comments
IMO Scheduler API should have been deprecated at the same time as LooperMode.LEGACY. I'll send out a PR to correct this. |
Scheduler API is obsolete and ShadowLooper APIs should be used instead. Related to #8976 PiperOrigin-RevId: 622908813
Scheduler API is obsolete and ShadowLooper APIs should be used instead. Related to #8976 PiperOrigin-RevId: 622943971
@kluever thanks for the post. These APIs are probably suboptimal. However, they are related to the legacy looper mode, which has been deprecated for 5+ years. There is not much point in investing a significant amount of resources to migrate something that is deprecated and obsolete to a more modern API. |
Instead of using an ambiguous (w.r.t. the unit)
long
to represent date/time concepts (like a delay or "now"), please use the appropriatejava.time
types (Duration
orInstant
).There's a bunch of APIs in
org.robolectric.util.Scheduler
that could be improved usingjava.time
types.The text was updated successfully, but these errors were encountered: