Commit cb2828c1 authored by Yue Zhang's avatar Yue Zhang Committed by Commit Bot

Add unit tests for TabGridDialogMediator

Bug: 979410
Change-Id: I520c1ad7619c5852ce0df0160a4ed5439329602b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1681025
Commit-Queue: Yue Zhang <yuezhanggg@google.com>
Reviewed-by: default avatarWei-Yin Chen (陳威尹) <wychen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#673446}
parent 42abe0d9
......@@ -9,6 +9,7 @@ import android.graphics.Rect;
import android.support.annotation.Nullable;
import android.view.View;
import org.chromium.base.VisibleForTesting;
import org.chromium.chrome.browser.tab.Tab;
import org.chromium.chrome.browser.tabmodel.EmptyTabModelObserver;
import org.chromium.chrome.browser.tabmodel.TabCreatorManager;
......@@ -246,4 +247,14 @@ public class TabGridDialogMediator {
updateDialog();
}
}
@VisibleForTesting
int getCurrentTabIdForTest() {
return mCurrentTabId;
}
@VisibleForTesting
void setCurrentTabIdForTest(int tabId) {
mCurrentTabId = tabId;
}
}
......@@ -20,6 +20,7 @@ tab_management_test_java_sources = [
tab_management_junit_java_sources = [
"//chrome/android/features/tab_ui/junit/src/org/chromium/chrome/browser/tasks/tab_management/GridTabSwitcherMediatorUnitTest.java",
"//chrome/android/features/tab_ui/junit/src/org/chromium/chrome/browser/tasks/tab_management/TabGridDialogMediatorUnitTest.java",
"//chrome/android/features/tab_ui/junit/src/org/chromium/chrome/browser/tasks/tab_management/TabGridItemTouchHelperCallbackUnitTest.java",
"//chrome/android/features/tab_ui/junit/src/org/chromium/chrome/browser/tasks/tab_management/TabListMediatorUnitTest.java",
]
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment