OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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/path_service.h" | 7 #include "base/path_service.h" |
8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
9 #include "base/values.h" | 9 #include "base/values.h" |
10 #include "chrome/common/chrome_paths.h" | 10 #include "chrome/common/chrome_paths.h" |
11 #include "chrome/common/chrome_switches.h" | 11 #include "chrome/common/chrome_switches.h" |
12 #include "chrome/common/json_value_serializer.h" | 12 #include "chrome/common/json_value_serializer.h" |
13 #include "chrome/test/automation/tab_proxy.h" | 13 #include "chrome/test/automation/tab_proxy.h" |
14 #include "chrome/test/ui/javascript_test_util.h" | 14 #include "chrome/test/ui/javascript_test_util.h" |
15 #include "chrome/test/ui/ui_test.h" | 15 #include "chrome/test/ui/ui_test.h" |
16 #include "googleurl/src/gurl.h" | 16 #include "googleurl/src/gurl.h" |
17 #include "net/base/net_util.h" | 17 #include "net/base/net_util.h" |
18 | 18 |
19 namespace { | 19 namespace { |
20 | 20 |
21 static const FilePath::CharType kStartFile[] = | 21 static const FilePath::CharType kStartFile[] = |
22 FILE_PATH_LITERAL("sunspider-driver.html"); | 22 FILE_PATH_LITERAL("sunspider-driver.html"); |
23 | 23 |
24 const wchar_t kRunSunSpider[] = L"run-sunspider"; | 24 const char kRunSunSpider[] = "run-sunspider"; |
25 | 25 |
26 class SunSpiderTest : public UITest { | 26 class SunSpiderTest : public UITest { |
27 public: | 27 public: |
28 typedef std::map<std::string, std::string> ResultsMap; | 28 typedef std::map<std::string, std::string> ResultsMap; |
29 | 29 |
30 SunSpiderTest() : reference_(false) { | 30 SunSpiderTest() : reference_(false) { |
31 dom_automation_enabled_ = true; | 31 dom_automation_enabled_ = true; |
32 show_window_ = true; | 32 show_window_ = true; |
33 } | 33 } |
34 | 34 |
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
146 } | 146 } |
147 | 147 |
148 TEST_F(SunSpiderReferenceTest, Perf) { | 148 TEST_F(SunSpiderReferenceTest, Perf) { |
149 if (!CommandLine::ForCurrentProcess()->HasSwitch(kRunSunSpider)) | 149 if (!CommandLine::ForCurrentProcess()->HasSwitch(kRunSunSpider)) |
150 return; | 150 return; |
151 | 151 |
152 RunTest(); | 152 RunTest(); |
153 } | 153 } |
154 | 154 |
155 } // namespace | 155 } // namespace |
OLD | NEW |