GalleryImageView extends FrameLayout implements Target { @Override public void onBitmapLoaded(Bitmap bitmap, Picasso.LoadedFrom from) { imageView.setImageBitmap(bitmap); progressBar.setVisibility(View.GONE); } GalleryImageView(Context context);   GalleryImageView(Context context, MultiTouchImageView imageView, ProgressBar progressBar); void setSwipeToDismissCallback(SwipeToDismissTouchListener.Callback callback); @Override void onBitmapLoaded(Bitmap bitmap, Picasso.LoadedFrom from); @Override void onBitmapFailed(Drawable errorDrawable); @Override void onPrepareLoad(Drawable placeHolderDrawable);  }
@Test public void testOnBitmapLoaded() { subject.onBitmapLoaded(bitmap, null); verify(subject.imageView).setImageBitmap(bitmap); verify(subject.progressBar).setVisibility(View.GONE); }