Skip to content

Commit

Permalink
Fixup the testutil package for the external build
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 368276634
  • Loading branch information
sjudd authored and glide-copybara-robot committed Apr 13, 2021
1 parent a2b759b commit 0ac564f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
5 changes: 5 additions & 0 deletions testutil/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.bumptech.glide.testutil">
<application/>
</manifest>
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,9 @@ public void clearOnMainThread(final ImageView imageView) {
runOnMainThread(
new Runnable() {
@Override
// Required to avoid a weird emulator issue where the Application passed here is otherwise
// cast to a FragmentActivity...
@SuppressWarnings("cast")
public void run() {
Glide.with((Context) ApplicationProvider.getApplicationContext()).clear(imageView);
}
Expand Down

0 comments on commit 0ac564f

Please sign in to comment.