diff options
author | Jay Shrauner <shrauner@google.com> | 2014-07-18 23:12:55 -0700 |
---|---|---|
committer | Jay Shrauner <shrauner@google.com> | 2014-07-18 23:22:13 -0700 |
commit | e13f5e1f88b197c890b1a753dc9c8ba9a0323f46 (patch) | |
tree | 746a15bc95df0e774ca2246a5a07b4696918b2df /tests/src | |
parent | e06611fa108e7e9aa1fe23f14c3433a80c3dcb17 (diff) |
Remove hardcoded class name from test
Bug:16347739
Change-Id: I810af831b782f0a7a6f3aa9df154c93c03c4080e
Diffstat (limited to 'tests/src')
-rw-r--r-- | tests/src/com/android/dialer/calllog/CallLogFragmentTest.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/src/com/android/dialer/calllog/CallLogFragmentTest.java b/tests/src/com/android/dialer/calllog/CallLogFragmentTest.java index 964d8a299..e0e111bcf 100644 --- a/tests/src/com/android/dialer/calllog/CallLogFragmentTest.java +++ b/tests/src/com/android/dialer/calllog/CallLogFragmentTest.java @@ -98,7 +98,7 @@ public class CallLogFragmentTest extends ActivityInstrumentationTestCase2<Fragme private View[] mList; public CallLogFragmentTest() { - super("com.android.dialer", FragmentTestActivity.class); + super(FragmentTestActivity.class); mIndex = 1; mRnd = new Random(); } @@ -400,7 +400,8 @@ public class CallLogFragmentTest extends ActivityInstrumentationTestCase2<Fragme */ private Bitmap getBitmap(String resName) { Resources r = mActivity.getResources(); - int resid = r.getIdentifier(resName, "drawable", "com.android.dialer"); + int resid = r.getIdentifier(resName, "drawable", + getInstrumentation().getTargetContext().getPackageName()); BitmapDrawable d = (BitmapDrawable) r.getDrawable(resid); assertNotNull(d); return d.getBitmap(); |