OLD | NEW |
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 "chrome/browser/prefs/incognito_mode_prefs.h" | 7 #include "chrome/browser/prefs/incognito_mode_prefs.h" |
8 #include "chrome/browser/prefs/pref_service.h" | 8 #include "chrome/browser/prefs/pref_service.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 17 matching lines...) Expand all Loading... |
28 DISABLED_UpdateWindowSizeExitsFullscreen | 28 DISABLED_UpdateWindowSizeExitsFullscreen |
29 #define MAYBE_UpdateWindowResize DISABLED_UpdateWindowResize | 29 #define MAYBE_UpdateWindowResize DISABLED_UpdateWindowResize |
30 #define MAYBE_UpdateWindowShowState DISABLED_UpdateWindowShowState | 30 #define MAYBE_UpdateWindowShowState DISABLED_UpdateWindowShowState |
31 #else | 31 #else |
32 #define MAYBE_FocusWindowDoesNotExitFullscreen FocusWindowDoesNotExitFullscreen | 32 #define MAYBE_FocusWindowDoesNotExitFullscreen FocusWindowDoesNotExitFullscreen |
33 #define MAYBE_UpdateWindowSizeExitsFullscreen UpdateWindowSizeExitsFullscreen | 33 #define MAYBE_UpdateWindowSizeExitsFullscreen UpdateWindowSizeExitsFullscreen |
34 #define MAYBE_UpdateWindowResize UpdateWindowResize | 34 #define MAYBE_UpdateWindowResize UpdateWindowResize |
35 #define MAYBE_UpdateWindowShowState UpdateWindowShowState | 35 #define MAYBE_UpdateWindowShowState UpdateWindowShowState |
36 #endif | 36 #endif |
37 | 37 |
38 // See crbug.com/108492. | 38 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, Tabs) { |
39 #if defined(USE_AURA) && defined(OS_CHROMEOS) | |
40 #define MAYBE_Tabs DISABLED_Tabs | |
41 #else | |
42 #define MAYBE_Tabs Tabs | |
43 #endif | |
44 | |
45 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, MAYBE_Tabs) { | |
46 // The test creates a tab and checks that the URL of the new tab | 39 // The test creates a tab and checks that the URL of the new tab |
47 // is that of the new tab page. Make sure the pref that controls | 40 // is that of the new tab page. Make sure the pref that controls |
48 // this is set. | 41 // this is set. |
49 browser()->profile()->GetPrefs()->SetBoolean( | 42 browser()->profile()->GetPrefs()->SetBoolean( |
50 prefs::kHomePageIsNewTabPage, true); | 43 prefs::kHomePageIsNewTabPage, true); |
51 | 44 |
52 ASSERT_TRUE(RunExtensionSubtest("tabs/basics", "crud.html")) << message_; | 45 ASSERT_TRUE(RunExtensionSubtest("tabs/basics", "crud.html")) << message_; |
53 } | 46 } |
54 | 47 |
55 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, Tabs2) { | 48 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, Tabs2) { |
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
206 } | 199 } |
207 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_GetViewsOfCreatedWindow) { | 200 IN_PROC_BROWSER_TEST_F(ExtensionApiTest, DISABLED_GetViewsOfCreatedWindow) { |
208 ASSERT_TRUE(RunExtensionSubtest("tabs/basics", "get_views_window.html")) | 201 ASSERT_TRUE(RunExtensionSubtest("tabs/basics", "get_views_window.html")) |
209 << message_; | 202 << message_; |
210 } | 203 } |
211 | 204 |
212 // Adding a new test? Awesome. But API tests are the old hotness. The | 205 // Adding a new test? Awesome. But API tests are the old hotness. The |
213 // new hotness is extension_test_utils. See extension_tabs_test.cc for | 206 // new hotness is extension_test_utils. See extension_tabs_test.cc for |
214 // an example. We are trying to phase out many uses of API tests as | 207 // an example. We are trying to phase out many uses of API tests as |
215 // they tend to be flaky. | 208 // they tend to be flaky. |
OLD | NEW |