OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "base/command_line.h" | 5 #include "base/command_line.h" |
6 #include "base/file_util.h" | 6 #include "base/file_util.h" |
7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
10 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
184 ShowAppListBrowserTest() {} | 184 ShowAppListBrowserTest() {} |
185 | 185 |
186 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { | 186 virtual void SetUpCommandLine(CommandLine* command_line) OVERRIDE { |
187 command_line->AppendSwitch(switches::kShowAppList); | 187 command_line->AppendSwitch(switches::kShowAppList); |
188 } | 188 } |
189 | 189 |
190 private: | 190 private: |
191 DISALLOW_COPY_AND_ASSIGN(ShowAppListBrowserTest); | 191 DISALLOW_COPY_AND_ASSIGN(ShowAppListBrowserTest); |
192 }; | 192 }; |
193 | 193 |
194 IN_PROC_BROWSER_TEST_F(ShowAppListBrowserTest, ShowAppListFlag) { | 194 // See http://crbug.com/315677 |
| 195 #if defined(OS_WIN) |
| 196 #define MAYBE_ShowAppListFlag DISABLED_ShowAppListFlag |
| 197 #else |
| 198 #define MAYBE_ShowAppListFlag ShowAppListFlag |
| 199 #endif |
| 200 |
| 201 IN_PROC_BROWSER_TEST_F(ShowAppListBrowserTest, MAYBE_ShowAppListFlag) { |
195 AppListService* service = GetAppListService(); | 202 AppListService* service = GetAppListService(); |
196 // The app list should already be shown because we passed | 203 // The app list should already be shown because we passed |
197 // switches::kShowAppList. | 204 // switches::kShowAppList. |
198 ASSERT_TRUE(service->IsAppListVisible()); | 205 ASSERT_TRUE(service->IsAppListVisible()); |
199 | 206 |
200 // Create a browser to prevent shutdown when we dismiss the app list. We | 207 // Create a browser to prevent shutdown when we dismiss the app list. We |
201 // need to do this because switches::kShowAppList suppresses the creation of | 208 // need to do this because switches::kShowAppList suppresses the creation of |
202 // any browsers. | 209 // any browsers. |
203 CreateBrowser(service->GetCurrentAppListProfile()); | 210 CreateBrowser(service->GetCurrentAppListProfile()); |
204 service->DismissAppList(); | 211 service->DismissAppList(); |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
325 // be removed from the model. | 332 // be removed from the model. |
326 EXPECT_TRUE(observed_result_); | 333 EXPECT_TRUE(observed_result_); |
327 base::RunLoop().RunUntilIdle(); | 334 base::RunLoop().RunUntilIdle(); |
328 EXPECT_FALSE(observed_result_); | 335 EXPECT_FALSE(observed_result_); |
329 StopWatchingResults(); | 336 StopWatchingResults(); |
330 service->DismissAppList(); | 337 service->DismissAppList(); |
331 } | 338 } |
332 #endif // !defined(OS_LINUX) | 339 #endif // !defined(OS_LINUX) |
333 | 340 |
334 } // namespace | 341 } // namespace |
OLD | NEW |