summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/src/com/android/dialer/calllog/CallLogFragmentTest.java14
-rw-r--r--tests/src/com/android/dialer/calllog/CallLogListItemHelperTest.java2
2 files changed, 9 insertions, 7 deletions
diff --git a/tests/src/com/android/dialer/calllog/CallLogFragmentTest.java b/tests/src/com/android/dialer/calllog/CallLogFragmentTest.java
index df6719c38..a739b16d2 100644
--- a/tests/src/com/android/dialer/calllog/CallLogFragmentTest.java
+++ b/tests/src/com/android/dialer/calllog/CallLogFragmentTest.java
@@ -326,13 +326,14 @@ public class CallLogFragmentTest extends ActivityInstrumentationTestCase2<Fragme
CallLogListItemViewHolder viewHolder = (CallLogListItemViewHolder)
mAdapter.onCreateViewHolder(mParentView, /* viewType */ 0);
bindViewForTest(viewHolder);
- viewHolder.updateCallButton();
+ viewHolder.updatePrimaryActionButton();
// The primaryActionView tag is set in the
// {@link com.android.dialer.calllog.CallLogAdapter#bindView} method. If it is possible
// to place a call to the phone number, a call intent will have been created for the
// primaryActionView.
- IntentProvider intentProvider = (IntentProvider) viewHolder.callActionView.getTag();
+ IntentProvider intentProvider =
+ (IntentProvider) viewHolder.primaryActionButtonView.getTag();
Intent intent = intentProvider.getIntent(mActivity);
// Starts a call.
assertEquals(TestConstants.CALL_INTENT_ACTION, intent.getAction());
@@ -375,12 +376,13 @@ public class CallLogFragmentTest extends ActivityInstrumentationTestCase2<Fragme
if (presentation == Calls.PRESENTATION_RESTRICTED ||
presentation == Calls.PRESENTATION_UNKNOWN) {
//If number is not callable, the primary action view should have a null tag.
- assertNull(mItem.callActionView.getTag());
+ assertNull(mItem.primaryActionButtonView.getTag());
} else {
//If the number is callable, the primary action view should have a non-null tag.
- assertNotNull(mItem.callActionView.getTag());
+ assertNotNull(mItem.primaryActionButtonView.getTag());
- IntentProvider intentProvider = (IntentProvider)mItem.callActionView.getTag();
+ IntentProvider intentProvider =
+ (IntentProvider) mItem.primaryActionButtonView.getTag();
Intent callIntent = intentProvider.getIntent(mActivity);
//The intent should be to make the call
@@ -457,7 +459,7 @@ public class CallLogFragmentTest extends ActivityInstrumentationTestCase2<Fragme
}
});
getInstrumentation().waitForIdleSync();
- viewHolder.updateCallButton();
+ viewHolder.updatePrimaryActionButton();
}
private void bindViewForTest(CallLogListItemViewHolder viewHolder) {
diff --git a/tests/src/com/android/dialer/calllog/CallLogListItemHelperTest.java b/tests/src/com/android/dialer/calllog/CallLogListItemHelperTest.java
index 091065b91..8ee85a436 100644
--- a/tests/src/com/android/dialer/calllog/CallLogListItemHelperTest.java
+++ b/tests/src/com/android/dialer/calllog/CallLogListItemHelperTest.java
@@ -78,7 +78,7 @@ public class CallLogListItemHelperTest extends AndroidTestCase {
public void testSetPhoneCallDetails() {
setPhoneCallDetailsWithNumber("12125551234", Calls.PRESENTATION_ALLOWED,
"1-212-555-1234");
- assertEquals(View.VISIBLE, mViewHolder.callActionView.getVisibility());
+ assertEquals(View.VISIBLE, mViewHolder.primaryActionButtonView.getVisibility());
}
public void testSetPhoneCallDetails_Unknown() {