Commit a4f67ccf by ibaker Committed by tonihei

Change DefaultHttpDataSourceTest to an instrumentation test

The Robolectric implementation of HttpURLConnection forwards to the JRE
implementation [1], which behaves differently to the Android one
available on devices and emulators. For these tests to be a realistic
test of the HTTP stack used in real playbacks we can't use Robolectric.

Similar to https://github.com/androidx/media/commit/d1e12dcddf0ea6d00a8b0d2df6786e7f06ad7e2f

[1] https://github.com/robolectric/robolectric/issues/6769#issuecomment-943556156

PiperOrigin-RevId: 416013662
parent 075ee7fb
...@@ -42,6 +42,7 @@ dependencies { ...@@ -42,6 +42,7 @@ dependencies {
androidTestImplementation 'androidx.test:runner:' + androidxTestRunnerVersion androidTestImplementation 'androidx.test:runner:' + androidxTestRunnerVersion
androidTestImplementation 'com.linkedin.dexmaker:dexmaker:' + dexmakerVersion androidTestImplementation 'com.linkedin.dexmaker:dexmaker:' + dexmakerVersion
androidTestImplementation 'com.linkedin.dexmaker:dexmaker-mockito:' + dexmakerVersion androidTestImplementation 'com.linkedin.dexmaker:dexmaker-mockito:' + dexmakerVersion
androidTestImplementation 'com.squareup.okhttp3:mockwebserver:' + okhttpVersion
androidTestImplementation(project(modulePrefix + 'test-utils')) { androidTestImplementation(project(modulePrefix + 'test-utils')) {
exclude module: modulePrefix.substring(1) + 'library-core' exclude module: modulePrefix.substring(1) + 'library-core'
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment