use of org.robolectric.plugins.SdkCollection in project robolectric by robolectric.
the class RobolectricTestRunnerMultiApiTest method withEnabledSdks_createChildrenForEachSupportedSdk.
@Test
public void withEnabledSdks_createChildrenForEachSupportedSdk() throws Throwable {
delegateSdkPicker = new DefaultSdkPicker(new SdkCollection(() -> map(16, 17)), null);
runner = runnerOf(TestWithNoConfig.class);
assertThat(runner.getChildren()).hasSize(2);
}
use of org.robolectric.plugins.SdkCollection in project robolectric by robolectric.
the class RobolectricTestRunnerMultiApiTest method setUp.
@Before
public void setUp() {
numSupportedApis = APIS_FOR_TEST.length;
runListener = new MyRunListener();
runNotifier = new RunNotifier();
runNotifier.addListener(runListener);
sdkCollection = new SdkCollection(() -> map(APIS_FOR_TEST));
delegateSdkPicker = new DefaultSdkPicker(sdkCollection, null);
priorResourcesMode = System.getProperty("robolectric.resourcesMode");
System.setProperty("robolectric.resourcesMode", "legacy");
priorAlwaysInclude = System.getProperty("robolectric.alwaysIncludeVariantMarkersInTestName");
System.clearProperty("robolectric.alwaysIncludeVariantMarkersInTestName");
}
Aggregations