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

Unified Diff: ios/chrome/test/earl_grey/chrome_test_case.h

Issue 2580333003: Upstream Chrome on iOS source code [10/11]. (Closed)
Patch Set: Created 4 years 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
« no previous file with comments | « ios/chrome/test/earl_grey/chrome_matchers.mm ('k') | ios/chrome/test/earl_grey/chrome_test_case.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/chrome/test/earl_grey/chrome_test_case.h
diff --git a/ios/chrome/test/earl_grey/chrome_test_case.h b/ios/chrome/test/earl_grey/chrome_test_case.h
new file mode 100644
index 0000000000000000000000000000000000000000..c0386138e8d0fe8495e932d85bef3936acec988d
--- /dev/null
+++ b/ios/chrome/test/earl_grey/chrome_test_case.h
@@ -0,0 +1,36 @@
+// Copyright 2016 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_GREY_CHROME_TEST_CASE_H_
+#define IOS_CHROME_TEST_EARL_GREY_CHROME_TEST_CASE_H_
+
+#import <XCTest/XCTest.h>
+
+#include "base/ios/block_types.h"
+
+// Base class for all Chrome Earl Grey tests.
+@interface ChromeTestCase : XCTestCase
+
+// Sets a block to always be executed at the end of a test during tearDown,
+// whether the test passes or fails. This shall only be set once per test.
+- (void)setTearDownHandler:(ProceduralBlock)tearDownHandler;
+
+// Removes any UI elements that are present, to ensure it is in a clean state.
++ (void)removeAnyOpenMenusAndInfoBars;
+
+// Closes all tabs, and waits for the UI to synchronize.
++ (void)closeAllTabs;
+
+// Turns off mock authentication. It will automatically be re-enabled at the
+// end of the test. This shall only be called once per test.
+- (void)disableMockAuthentication;
+
+// Stops the HTTP server. It will be re-started at the end of the test. This
+// should only be called when the HTTP server is running. This shall only be
+// called once per test.
+- (void)stopHTTPServer;
+
+@end
+
+#endif // IOS_CHROME_TEST_EARL_GREY_CHROME_TEST_CASE_H_
« no previous file with comments | « ios/chrome/test/earl_grey/chrome_matchers.mm ('k') | ios/chrome/test/earl_grey/chrome_test_case.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698