Skip to content

Instantly share code, notes, and snippets.

@reza-id
reza-id / CustomMatchers.kt
Created November 20, 2018 11:07
Espresso Custom View Matcher to check Vector Drawable Icon
import android.content.Context
import android.graphics.Bitmap
import android.graphics.Canvas
import android.graphics.drawable.BitmapDrawable
import android.graphics.drawable.Drawable
import android.graphics.drawable.StateListDrawable
import android.graphics.drawable.VectorDrawable
import android.support.annotation.DrawableRes
import android.support.test.espresso.matcher.BoundedMatcher
import android.support.v4.content.ContextCompat