use of android.hardware.location.ContextHubClient in project robolectric by robolectric.
the class ShadowContextHubManagerTest method createClient_returnsValidClient.
@Test
@Config(minSdk = Build.VERSION_CODES.P)
public void createClient_returnsValidClient() {
ContextHubManager contextHubManager = (ContextHubManager) context.getSystemService(Context.CONTEXTHUB_SERVICE);
ContextHubClient contextHubClient = contextHubManager.createClient(null, null);
assertThat(contextHubClient).isNotNull();
}
use of android.hardware.location.ContextHubClient in project robolectric by robolectric.
the class ShadowContextHubManager method createClient.
@Implementation(minSdk = VERSION_CODES.S)
@HiddenApi
protected Object createClient(Context context, ContextHubInfo hubInfo, PendingIntent pendingIntent, long nanoAppId) {
ContextHubClient client = Shadow.newInstance(ContextHubClient.class, new Class<?>[] { ContextHubInfo.class, Boolean.TYPE }, new Object[] { hubInfo, false });
contextHubClientWithPendingIntentList.add(client);
return client;
}
Aggregations