Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1613)

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/ntp/cards/NewTabPageRecyclerView.java

Issue 2670863004: 🏠 Add instrumentation test for Suggestions BottomSheet (Closed)
Patch Set: fix compilation, comments Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/android/java/src/org/chromium/chrome/browser/ntp/cards/NewTabPageRecyclerView.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/ntp/cards/NewTabPageRecyclerView.java b/chrome/android/java/src/org/chromium/chrome/browser/ntp/cards/NewTabPageRecyclerView.java
index d3ff538eb437e0afc9283c9dcb12a363c8c17959..7b998b50ba89b9a04f39cd9393e515881913cd47 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/ntp/cards/NewTabPageRecyclerView.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/ntp/cards/NewTabPageRecyclerView.java
@@ -28,6 +28,7 @@
import org.chromium.base.Callback;
import org.chromium.base.Log;
+import org.chromium.base.VisibleForTesting;
import org.chromium.chrome.R;
import org.chromium.chrome.R.string;
import org.chromium.chrome.browser.ntp.ContextMenuManager.TouchDisableableView;
@@ -376,7 +377,8 @@ private SectionHeaderViewHolder findFirstHeader() {
* Finds the view holder for the first card.
* @return The {@code ViewHolder} for the first card, or null if it is not present.
*/
- private CardViewHolder findFirstCard() {
+ @VisibleForTesting
+ public CardViewHolder findFirstCard() {
int position = getNewTabPageAdapter().getFirstCardPosition();
if (position == RecyclerView.NO_POSITION) return null;

Powered by Google App Engine
This is Rietveld 408576698