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

Side by Side Diff: chrome/browser/extensions/extension_tabs_apitest.cc

Issue 16268017: GTTF: convert some tests in chrome to use EmbeddedTestServer patch nr 1 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 6 months 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/extensions/extension_apitest.h" 5 #include "chrome/browser/extensions/extension_apitest.h"
6 6
7 #include "base/prefs/pref_service.h" 7 #include "base/prefs/pref_service.h"
8 #include "chrome/browser/prefs/incognito_mode_prefs.h" 8 #include "chrome/browser/prefs/incognito_mode_prefs.h"
9 #include "chrome/browser/profiles/profile.h" 9 #include "chrome/browser/profiles/profile.h"
10 #include "chrome/browser/ui/browser.h" 10 #include "chrome/browser/ui/browser.h"
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, MAYBE_TabOpener) { 133 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, MAYBE_TabOpener) {
134 ASSERT_TRUE(RunExtensionSubtest("tabs/basics", "opener.html")) << message_; 134 ASSERT_TRUE(RunExtensionSubtest("tabs/basics", "opener.html")) << message_;
135 } 135 }
136 136
137 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_TabGetCurrent) { 137 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_TabGetCurrent) {
138 ASSERT_TRUE(RunExtensionTest("tabs/get_current")) << message_; 138 ASSERT_TRUE(RunExtensionTest("tabs/get_current")) << message_;
139 } 139 }
140 140
141 // Flaky on the trybots. See http://crbug.com/96725. 141 // Flaky on the trybots. See http://crbug.com/96725.
142 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_TabConnect) { 142 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_TabConnect) {
143 ASSERT_TRUE(StartTestServer()); 143 ASSERT_TRUE(StartEmbeddedTestServer());
144 ASSERT_TRUE(RunExtensionTest("tabs/connect")) << message_; 144 ASSERT_TRUE(RunExtensionTest("tabs/connect")) << message_;
145 } 145 }
146 146
147 // Possible race in ChromeURLDataManager. http://crbug.com/59198 147 // Possible race in ChromeURLDataManager. http://crbug.com/59198
148 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_TabOnRemoved) { 148 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_TabOnRemoved) {
149 ASSERT_TRUE(RunExtensionTest("tabs/on_removed")) << message_; 149 ASSERT_TRUE(RunExtensionTest("tabs/on_removed")) << message_;
150 } 150 }
151 151
152 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_TabReload) { 152 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_TabReload) {
153 ASSERT_TRUE(RunExtensionTest("tabs/reload")) << message_; 153 ASSERT_TRUE(RunExtensionTest("tabs/reload")) << message_;
154 } 154 }
155 155
156 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_CaptureVisibleTabJpeg) { 156 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_CaptureVisibleTabJpeg) {
157 host_resolver()->AddRule("a.com", "127.0.0.1"); 157 host_resolver()->AddRule("a.com", "127.0.0.1");
158 host_resolver()->AddRule("b.com", "127.0.0.1"); 158 host_resolver()->AddRule("b.com", "127.0.0.1");
159 ASSERT_TRUE(StartTestServer()); 159 ASSERT_TRUE(StartEmbeddedTestServer());
160 ASSERT_TRUE(RunExtensionSubtest("tabs/capture_visible_tab", 160 ASSERT_TRUE(RunExtensionSubtest("tabs/capture_visible_tab",
161 "test_jpeg.html")) << message_; 161 "test_jpeg.html")) << message_;
162 } 162 }
163 163
164 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_CaptureVisibleTabPng) { 164 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_CaptureVisibleTabPng) {
165 host_resolver()->AddRule("a.com", "127.0.0.1"); 165 host_resolver()->AddRule("a.com", "127.0.0.1");
166 host_resolver()->AddRule("b.com", "127.0.0.1"); 166 host_resolver()->AddRule("b.com", "127.0.0.1");
167 ASSERT_TRUE(StartTestServer()); 167 ASSERT_TRUE(StartEmbeddedTestServer());
168 ASSERT_TRUE(RunExtensionSubtest("tabs/capture_visible_tab", 168 ASSERT_TRUE(RunExtensionSubtest("tabs/capture_visible_tab",
169 "test_png.html")) << message_; 169 "test_png.html")) << message_;
170 } 170 }
171 171
172 // Times out on non-Windows. 172 // Times out on non-Windows.
173 // See http://crbug.com/80212 173 // See http://crbug.com/80212
174 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_CaptureVisibleTabRace) { 174 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_CaptureVisibleTabRace) {
175 ASSERT_TRUE(RunExtensionSubtest("tabs/capture_visible_tab", 175 ASSERT_TRUE(RunExtensionSubtest("tabs/capture_visible_tab",
176 "test_race.html")) << message_; 176 "test_race.html")) << message_;
177 } 177 }
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
240 << message_; 240 << message_;
241 } 241 }
242 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_GetViewsOfCreatedWindow) { 242 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_GetViewsOfCreatedWindow) {
243 ASSERT_TRUE(RunExtensionSubtest("tabs/basics", "get_views_window.html")) 243 ASSERT_TRUE(RunExtensionSubtest("tabs/basics", "get_views_window.html"))
244 << message_; 244 << message_;
245 } 245 }
246 246
247 // Adding a new test? Awesome. But API tests are the old hotness. The 247 // Adding a new test? Awesome. But API tests are the old hotness. The
248 // new hotness is extension_test_utils. See tabs_test.cc for an example. 248 // new hotness is extension_test_utils. See tabs_test.cc for an example.
249 // We are trying to phase out many uses of API tests as they tend to be flaky. 249 // We are trying to phase out many uses of API tests as they tend to be flaky.
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_messages_apitest.cc ('k') | chrome/browser/extensions/isolated_app_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698