List of usage examples for android.content SyncResult getClass
@HotSpotIntrinsicCandidate public final native Class<?> getClass();
From source file:com.android.tests.lib.LibUnitTest.java
@Test public void instanceFields() throws Exception { SyncResult result = mock(SyncResult.class); Field statsField = result.getClass().getField("stats"); SyncStats syncStats = mock(SyncStats.class); statsField.set(result, syncStats);//from w ww . j av a2 s .c o m syncStats.numDeletes = 42; assertEquals(42, result.stats.numDeletes); }