Commit f4b59941 authored by zhaoyangli's avatar zhaoyangli Committed by Commit Bot

Remove chrome_earl_grey_edo.h from ios/chrome/test/earl_grey2

The file and class don't follow current convention. Remove the class
and it's use case from codebase.

Bug: 1002989

Change-Id: I0896cb1a010d19e24d5157cc5275f10e167c7a38
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1865428Reviewed-by: default avatarEugene But <eugenebut@chromium.org>
Commit-Queue: Zhaoyang Li <zhaoyangli@chromium.org>
Cr-Commit-Position: refs/heads/master@{#706690}
parent 28638525
......@@ -53,34 +53,6 @@ chrome_ios_eg2_test("ios_chrome_ui_eg2tests_module") {
]
}
source_set("shared_helper_headers") {
testonly = true
sources = [
"//ios/chrome/test/earl_grey2/chrome_earl_grey_edo.h",
]
}
source_set("eg_app_support+eg2") {
testonly = true
configs += [ "//build/config/compiler:enable_arc" ]
sources = [
"chrome_earl_grey_edo.mm",
]
deps = [
"//base",
"//base/test:test_support",
"//ios/chrome/test/app:test_support",
"//ios/testing/earl_grey:eg_app_support+eg2",
"//ios/third_party/earl_grey2:app_framework+link",
]
public_deps = [
":shared_helper_headers",
]
}
source_set("eg2_tests") {
defines = [ "CHROME_EARL_GREY_2" ]
configs += [
......@@ -94,7 +66,6 @@ source_set("eg2_tests") {
]
deps = [
":shared_helper_headers",
"//ios/chrome/app/strings",
"//ios/chrome/browser/ui:feature_flags",
"//ios/chrome/test/earl_grey:eg_test_support+eg2",
......
// Copyright 2018 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef IOS_CHROME_TEST_EARL_GREY2_CHROME_EARL_GREY_EDO_H_
#define IOS_CHROME_TEST_EARL_GREY2_CHROME_EARL_GREY_EDO_H_
#import <CommonLib/DistantObject/GREYHostApplicationDistantObject.h>
@interface GREYHostApplicationDistantObject (RemoteTest)
// Returns the number of main tabs.
- (NSUInteger)GetMainTabCount;
@end
#endif // IOS_CHROME_TEST_EARL_GREY2_CHROME_EARL_GREY_EDO_H_
// Copyright 2018 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#import "ios/chrome/test/earl_grey2/chrome_earl_grey_edo.h"
#import "ios/chrome/test/app/tab_test_util.h"
#if !defined(__has_feature) || !__has_feature(objc_arc)
#error "This file requires ARC support."
#endif
@implementation GREYHostApplicationDistantObject (RemoteTest)
- (NSUInteger)GetMainTabCount {
return chrome_test_util::GetMainTabCount();
}
@end
......@@ -91,7 +91,6 @@ template("chrome_ios_eg2_test_app_host") {
"//ios/chrome/app:main",
"//ios/chrome/test/earl_grey:eg_app_support+eg2",
"//ios/chrome/test/earl_grey:hooks",
"//ios/chrome/test/earl_grey2:eg_app_support+eg2",
"//ios/testing:http_server_bundle_data",
"//ios/third_party/earl_grey2:app_framework+link",
]
......
......@@ -12,7 +12,6 @@
#import "ios/chrome/test/earl_grey/chrome_earl_grey_ui.h"
#import "ios/chrome/test/earl_grey/chrome_matchers.h"
#import "ios/chrome/test/earl_grey/chrome_test_case.h"
#import "ios/chrome/test/earl_grey2/chrome_earl_grey_edo.h"
#import "ios/testing/earl_grey/app_launch_manager.h"
#import "ios/testing/earl_grey/earl_grey_test.h"
#import "ios/web/common/features.h"
......@@ -43,10 +42,8 @@
[[EarlGrey selectElementWithMatcher:newTabButtonMatcher]
performAction:grey_tap()];
// Get tab count.
NSUInteger tabCount =
[[GREYHostApplicationDistantObject sharedInstance] GetMainTabCount];
GREYAssertEqual(2, tabCount, @"Expected 2 tabs.");
// Wait until tab opened and test if there're 2 tabs in total.
[ChromeEarlGrey waitForMainTabCount:2];
}
// Tests that helpers from chrome_matchers.h are available for use in tests.
......
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