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

Side by Side Diff: chrome/test/ui/inspector_controller_uitest.cc

Issue 18248: CommandLine API rework (Closed)
Patch Set: fixes Created 11 years, 11 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
« no previous file with comments | « chrome/test/startup/startup_test.cc ('k') | chrome/test/ui/omnibox_uitest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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/no_windows2000_unittest.h" 6 #include "base/no_windows2000_unittest.h"
7 #include "base/win_util.h" 7 #include "base/win_util.h"
8 #include "chrome/common/chrome_switches.h" 8 #include "chrome/common/chrome_switches.h"
9 #include "chrome/test/automation/browser_proxy.h" 9 #include "chrome/test/automation/browser_proxy.h"
10 #include "chrome/test/automation/tab_proxy.h" 10 #include "chrome/test/automation/tab_proxy.h"
(...skipping 16 matching lines...) Expand all
27 ASSERT_TRUE(tab_proxy->NavigateToURL(url)); 27 ASSERT_TRUE(tab_proxy->NavigateToURL(url));
28 } 28 }
29 }; 29 };
30 30
31 // This test also does not work in single process. See http://b/1214920 31 // This test also does not work in single process. See http://b/1214920
32 // Disabled, see http://crbug.com/4655 32 // Disabled, see http://crbug.com/4655
33 TEST_F(InspectorControllerTest, DISABLED_InspectElement) { 33 TEST_F(InspectorControllerTest, DISABLED_InspectElement) {
34 if (IsTestCaseDisabled()) 34 if (IsTestCaseDisabled())
35 return; 35 return;
36 36
37 if (CommandLine().HasSwitch(switches::kSingleProcess)) 37 if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kSingleProcess))
38 return; 38 return;
39 39
40 scoped_refptr<HTTPTestServer> server = 40 scoped_refptr<HTTPTestServer> server =
41 HTTPTestServer::CreateServer(L"chrome/test/data"); 41 HTTPTestServer::CreateServer(L"chrome/test/data");
42 ASSERT_TRUE(NULL != server.get()); 42 ASSERT_TRUE(NULL != server.get());
43 43
44 ::scoped_ptr<TabProxy> tab(GetActiveTabProxy()); 44 ::scoped_ptr<TabProxy> tab(GetActiveTabProxy());
45 // We don't track resources until we've opened the inspector. 45 // We don't track resources until we've opened the inspector.
46 NavigateTab(tab.get(), server->TestServerPageW( 46 NavigateTab(tab.get(), server->TestServerPageW(
47 L"files/inspector/test1.html")); 47 L"files/inspector/test1.html"));
48 tab->InspectElement(0, 0); 48 tab->InspectElement(0, 0);
49 NavigateTab(tab.get(), server->TestServerPageW( 49 NavigateTab(tab.get(), server->TestServerPageW(
50 L"files/inspector/test1.html")); 50 L"files/inspector/test1.html"));
51 EXPECT_EQ(1, tab->InspectElement(0, 0)); 51 EXPECT_EQ(1, tab->InspectElement(0, 0));
52 NavigateTab(tab.get(), server->TestServerPageW( 52 NavigateTab(tab.get(), server->TestServerPageW(
53 L"files/inspector/test2.html")); 53 L"files/inspector/test2.html"));
54 EXPECT_EQ(2, tab->InspectElement(0, 0)); 54 EXPECT_EQ(2, tab->InspectElement(0, 0));
55 } 55 }
56 56
OLDNEW
« no previous file with comments | « chrome/test/startup/startup_test.cc ('k') | chrome/test/ui/omnibox_uitest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698