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

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

First pass of "real" services on Ravenwood.

One of our eventual goals with Ravenwood is to support usage of
system services from test code.  Robolectric takes the approach of
publishing "shadows" which are effectively fakes of the Manager
objects visible to app processes, and it unfortunately doesn't offer
a mechanism to run "real" services code.

In contrast, Ravenwood aims to support API owners progressively
offering their system services either via a "fake" approach, or by
using various levels of the "real" code that would run on a device.

This change wires up the foundational support and uses the simple
`SerialManager` example to demonstrate using the same "real" code
on both Ravenwood and devices.  It also demonstrates the `Internal`
pattern being used to customize behavior for tests.

To offer as hermetic as a test environment as possible, we start
new instances of each requested service for each test.  Requiring
developers to be explicit about the services they need will help
keep overhead low, especially for tests that don't need services.

Bug: 325506297
Test: atest RavenwoodServicesTest
Change-Id: Ie22436b38f2176f91dfce746b899ebab7752bbb8
parent f1790276
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment