Commit 7a87b415 authored by Justin Cohen's avatar Justin Cohen Committed by Commit Bot

[ios] Remove old recent tab tests.

Bug: 807330
Cq-Include-Trybots: luci.chromium.try:ios-simulator-cronet;luci.chromium.try:ios-simulator-full-configs
Change-Id: I988192d63f2189524b86c5ccd40f64fe42aebf40
Reviewed-on: https://chromium-review.googlesource.com/1228515
Commit-Queue: Justin Cohen <justincohen@chromium.org>
Reviewed-by: default avatarSergio Collazos <sczs@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592782}
parent 766637ea
......@@ -74,21 +74,14 @@ id<GREYMatcher> TitleOfTestPage() {
web::test::HttpServer::MakeUrl(kURLOfTestPage),
std::string(kHTMLOfTestPage),
}});
if (IsUIRefreshPhase1Enabled()) {
[NSUserDefaults.standardUserDefaults setObject:@{}
forKey:kListModelCollapsedKey];
} else {
[NSUserDefaults.standardUserDefaults setObject:@{}
forKey:kCollapsedSectionsKey];
}
[NSUserDefaults.standardUserDefaults setObject:@{}
forKey:kListModelCollapsedKey];
}
// Closes the recent tabs panel.
- (void)closeRecentTabs {
NSString* exitID = IsUIRefreshPhase1Enabled()
? kTableViewNavigationDismissButtonId
: @"Exit";
id<GREYMatcher> exitMatcher = grey_accessibilityID(exitID);
id<GREYMatcher> exitMatcher =
grey_accessibilityID(kTableViewNavigationDismissButtonId);
[[EarlGrey selectElementWithMatcher:exitMatcher] performAction:grey_tap()];
// Wait until the recent tabs panel is dismissed.
[[GREYUIThreadExecutor sharedInstance] drainUntilIdle];
......@@ -137,11 +130,8 @@ id<GREYMatcher> TitleOfTestPage() {
// Tap "Show Full History"
id<GREYMatcher> showHistoryMatcher =
IsUIRefreshPhase1Enabled()
? chrome_test_util::StaticTextWithAccessibilityLabelId(
IDS_HISTORY_SHOWFULLHISTORY_LINK)
: chrome_test_util::ButtonWithAccessibilityLabelId(
IDS_HISTORY_SHOWFULLHISTORY_LINK);
chrome_test_util::StaticTextWithAccessibilityLabelId(
IDS_HISTORY_SHOWFULLHISTORY_LINK);
[[EarlGrey selectElementWithMatcher:showHistoryMatcher]
performAction:grey_tap()];
......@@ -156,17 +146,9 @@ id<GREYMatcher> TitleOfTestPage() {
assertWithMatcher:grey_sufficientlyVisible()];
// Close History.
if (IsUIRefreshPhase1Enabled()) {
id<GREYMatcher> exitMatcher =
grey_accessibilityID(kHistoryNavigationControllerDoneButtonIdentifier);
[[EarlGrey selectElementWithMatcher:exitMatcher] performAction:grey_tap()];
} else {
[[EarlGrey
selectElementWithMatcher:chrome_test_util::ButtonWithAccessibilityLabel(
l10n_util::GetNSString(
IDS_IOS_NAVIGATION_BAR_DONE_BUTTON))]
performAction:grey_tap()];
}
id<GREYMatcher> exitMatcher =
grey_accessibilityID(kHistoryNavigationControllerDoneButtonIdentifier);
[[EarlGrey selectElementWithMatcher:exitMatcher] performAction:grey_tap()];
// Close tab.
chrome_test_util::CloseCurrentTab();
......
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