Index: chrome/browser/interstitials/security_interstitial_page_test_utils.h |
diff --git a/chrome/browser/interstitials/security_interstitial_page_test_utils.h b/chrome/browser/interstitials/security_interstitial_page_test_utils.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..8d4fbaad912766ceec546f4203fbd6e76556e4e9 |
--- /dev/null |
+++ b/chrome/browser/interstitials/security_interstitial_page_test_utils.h |
@@ -0,0 +1,44 @@ |
+// Copyright 2015 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 CHROME_BROWSER_INTERSTITIALS_SECURITY_INTERSTITIAL_PAGE_TEST_UTILS_H_ |
+#define CHROME_BROWSER_INTERSTITIALS_SECURITY_INTERSTITIAL_PAGE_TEST_UTILS_H_ |
+ |
+#include <string> |
+ |
+#include "chrome/test/base/in_process_browser_test.h" |
+ |
+namespace content { |
+class InterstitialPage; |
+class WebContents; |
+} |
+ |
+class GURL; |
+class SecurityInterstitialPage; |
+ |
+namespace chrome_browser_interstitials { |
+ |
+bool IsInterstitialDisplayingText(content::InterstitialPage* interstitial, |
+ const std::string& text); |
+ |
+// This class is used for testing the display of IDN names in security |
+// interstitials. |
+class SecurityInterstitialIDNTest : public InProcessBrowserTest { |
+ public: |
+ // InProcessBrowserTest implementation |
+ void SetUpOnMainThread() override; |
+ |
+ // Run a test that creates an interstitial with an IDN request URL |
+ // and checks that it is properly decoded. |
+ void TestIDN(); |
meacer
2015/03/24 23:16:59
const method?
meacer
2015/03/24 23:16:59
You can also return an AssertionResult here. E.g.
estark
2015/03/25 00:45:25
Done.
estark
2015/03/25 00:45:25
Done.
(Question: is the purpose of returning an A
meacer
2015/03/25 01:08:39
In this case, yes I think it's slight more readabl
estark
2015/03/25 04:23:49
Makes sense, thanks!
|
+ |
+ protected: |
+ virtual SecurityInterstitialPage* CreateInterstitial( |
+ content::WebContents* contents, |
+ const GURL& request_url) = 0; |
meacer
2015/03/24 23:16:59
const method?
estark
2015/03/25 00:45:25
Done.
|
+}; |
+ |
+} // namespace chrome_browser_interstitials |
+ |
+#endif // CHROME_BROWSER_INTERSTITIALS_SECURITY_INTERSTITIAL_PAGE_TEST_UTILS_H_ |