diff options
25 files changed, 34 insertions, 36 deletions
diff --git a/base/base.gyp b/base/base.gyp index 39e9f33..fabc868 100644 --- a/base/base.gyp +++ b/base/base.gyp @@ -865,7 +865,6 @@ }], ], 'sources': [ - 'perftimer.cc', 'test/expectations/expectation.cc', 'test/expectations/expectation.h', 'test/expectations/parser.cc', @@ -885,6 +884,7 @@ 'test/null_task_runner.h', 'test/perf_test_suite.cc', 'test/perf_test_suite.h', + 'test/perftimer.cc', 'test/power_monitor_test_base.cc', 'test/power_monitor_test_base.h', 'test/scoped_locale.cc', @@ -935,9 +935,9 @@ 'test/thread_test_helper.h', 'test/trace_event_analyzer.cc', 'test/trace_event_analyzer.h', - 'test/unit_test_launcher_ios.cc', 'test/unit_test_launcher.cc', 'test/unit_test_launcher.h', + 'test/unit_test_launcher_ios.cc', 'test/values_test_util.cc', 'test/values_test_util.h', ], @@ -963,7 +963,7 @@ '../testing/gtest.gyp:gtest', ], 'sources': [ - 'perftimer.cc', + 'test/perftimer.cc', 'test/run_all_perftests.cc', ], 'direct_dependent_settings': { diff --git a/base/test/perf_test_suite.cc b/base/test/perf_test_suite.cc index 8cfbb73..86be119 100644 --- a/base/test/perf_test_suite.cc +++ b/base/test/perf_test_suite.cc @@ -8,9 +8,9 @@ #include "base/debug/debugger.h" #include "base/files/file_path.h" #include "base/path_service.h" -#include "base/perftimer.h" #include "base/process/launch.h" #include "base/strings/string_util.h" +#include "base/test/perftimer.h" #include "testing/gtest/include/gtest/gtest.h" namespace base { diff --git a/base/perftimer.cc b/base/test/perftimer.cc index 9ab7c6b..6815f0b 100644 --- a/base/perftimer.cc +++ b/base/test/perftimer.cc @@ -1,8 +1,8 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Copyright 2013 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "base/perftimer.h" +#include "base/test/perftimer.h" #include <stdio.h> #include <string> diff --git a/base/perftimer.h b/base/test/perftimer.h index 466f81d..1a26cf5 100644 --- a/base/perftimer.h +++ b/base/test/perftimer.h @@ -1,9 +1,9 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Copyright 2013 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#ifndef BASE_PERFTIMER_H_ -#define BASE_PERFTIMER_H_ +#ifndef BASE_TEST_PERFTIMER_H_ +#define BASE_TEST_PERFTIMER_H_ #include <string> @@ -82,4 +82,4 @@ class PerfTimeLogger { PerfTimer timer_; }; -#endif // BASE_PERFTIMER_H_ +#endif // BASE_TEST_PERFTIMER_H_ diff --git a/chrome/browser/chromeos/external_metrics.cc b/chrome/browser/chromeos/external_metrics.cc index 37e6703..4e7dd11 100644 --- a/chrome/browser/chromeos/external_metrics.cc +++ b/chrome/browser/chromeos/external_metrics.cc @@ -23,9 +23,9 @@ #include "base/metrics/histogram.h" #include "base/metrics/sparse_histogram.h" #include "base/metrics/statistics_recorder.h" -#include "base/perftimer.h" #include "base/posix/eintr_wrapper.h" #include "base/sys_info.h" +#include "base/test/perftimer.h" #include "base/time/time.h" #include "chrome/browser/browser_process.h" #include "chrome/browser/metrics/metrics_service.h" diff --git a/chrome/browser/extensions/extension_host.h b/chrome/browser/extensions/extension_host.h index f4e8886..3b084e4 100644 --- a/chrome/browser/extensions/extension_host.h +++ b/chrome/browser/extensions/extension_host.h @@ -10,7 +10,7 @@ #include "base/logging.h" #include "base/memory/scoped_ptr.h" -#include "base/perftimer.h" +#include "base/test/perftimer.h" #include "chrome/browser/extensions/extension_function_dispatcher.h" #include "content/public/browser/javascript_dialog_manager.h" #include "content/public/browser/notification_observer.h" diff --git a/chrome/browser/metrics/metrics_log.cc b/chrome/browser/metrics/metrics_log.cc index bebdad2..d5403271 100644 --- a/chrome/browser/metrics/metrics_log.cc +++ b/chrome/browser/metrics/metrics_log.cc @@ -13,7 +13,6 @@ #include "base/cpu.h" #include "base/lazy_instance.h" #include "base/memory/scoped_ptr.h" -#include "base/perftimer.h" #include "base/prefs/pref_registry_simple.h" #include "base/prefs/pref_service.h" #include "base/profiler/alternate_timer.h" @@ -21,6 +20,7 @@ #include "base/strings/string_util.h" #include "base/strings/utf_string_conversions.h" #include "base/sys_info.h" +#include "base/test/perftimer.h" #include "base/third_party/nspr/prtime.h" #include "base/time/time.h" #include "base/tracked_objects.h" diff --git a/chrome/renderer/extensions/user_script_slave.cc b/chrome/renderer/extensions/user_script_slave.cc index d309188..044859a 100644 --- a/chrome/renderer/extensions/user_script_slave.cc +++ b/chrome/renderer/extensions/user_script_slave.cc @@ -10,9 +10,9 @@ #include "base/logging.h" #include "base/memory/shared_memory.h" #include "base/metrics/histogram.h" -#include "base/perftimer.h" #include "base/pickle.h" #include "base/strings/stringprintf.h" +#include "base/test/perftimer.h" #include "chrome/common/extensions/csp_handler.h" #include "chrome/common/extensions/extension.h" #include "chrome/common/extensions/extension_messages.h" diff --git a/chrome/renderer/safe_browsing/phishing_url_feature_extractor.cc b/chrome/renderer/safe_browsing/phishing_url_feature_extractor.cc index 5fda969..a43f0ca 100644 --- a/chrome/renderer/safe_browsing/phishing_url_feature_extractor.cc +++ b/chrome/renderer/safe_browsing/phishing_url_feature_extractor.cc @@ -10,9 +10,9 @@ #include "base/logging.h" #include "base/metrics/histogram.h" -#include "base/perftimer.h" #include "base/strings/string_split.h" #include "base/strings/string_util.h" +#include "base/test/perftimer.h" #include "chrome/renderer/safe_browsing/features.h" #include "net/base/registry_controlled_domains/registry_controlled_domain.h" #include "url/gurl.h" diff --git a/chrome/test/perf/feature_startup_test.cc b/chrome/test/perf/feature_startup_test.cc index d75e4d2..73b4fa3 100644 --- a/chrome/test/perf/feature_startup_test.cc +++ b/chrome/test/perf/feature_startup_test.cc @@ -3,8 +3,8 @@ // found in the LICENSE file. #include "base/path_service.h" -#include "base/perftimer.h" #include "base/strings/stringprintf.h" +#include "base/test/perftimer.h" #include "base/time/time.h" #include "chrome/app/chrome_command_ids.h" #include "chrome/common/chrome_paths.h" diff --git a/chrome/test/perf/url_parse_perftest.cc b/chrome/test/perf/url_parse_perftest.cc index 20662f7..3aadd06 100644 --- a/chrome/test/perf/url_parse_perftest.cc +++ b/chrome/test/perf/url_parse_perftest.cc @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "base/perftimer.h" +#include "base/test/perftimer.h" #include "testing/gtest/include/gtest/gtest.h" #include "url/gurl.h" #include "url/url_canon.h" @@ -18,8 +18,8 @@ #include "webkit/third_party/WebCore/platform/CString.h" #define KURL WebKitKURL -#include "KURL.h" #include "KURL.cpp" +#include "KURL.h" #pragma warning(pop) TEST(URLParse, FullURL) { @@ -45,7 +45,7 @@ int typical_url2_len = static_cast<int>(strlen(typical_url2)); const char typical_url3[] = "http://store.apple.com/1-800-MY-APPLE/WebObjects/AppleStore.woa/wa/RSLID?nnmm=browse&mco=578E9744&node=home/desktop/mac_pro"; int typical_url3_len = static_cast<int>(strlen(typical_url3)); -} +} // namespace TEST(URLParse, TypicalURLParse) { url_parse::Parsed parsed1; diff --git a/chrome_frame/chrome_frame.gyp b/chrome_frame/chrome_frame.gyp index f9d13a5..06648be 100644 --- a/chrome_frame/chrome_frame.gyp +++ b/chrome_frame/chrome_frame.gyp @@ -350,7 +350,7 @@ ], 'sources': [ '../base/test/perf_test_suite.h', - '../base/perftimer.cc', + '../base/test/perftimer.cc', '../base/test/test_file_util.h', '../chrome/test/base/chrome_process_util.cc', '../chrome/test/base/chrome_process_util.h', diff --git a/chrome_frame/test/perf/chrome_frame_perftest.h b/chrome_frame/test/perf/chrome_frame_perftest.h index 370ae5c..8209846 100644 --- a/chrome_frame/test/perf/chrome_frame_perftest.h +++ b/chrome_frame/test/perf/chrome_frame_perftest.h @@ -4,7 +4,7 @@ #ifndef CHROME_FRAME_TEST_PERF_CHROME_FRAME_PERFTEST_H_ #define CHROME_FRAME_TEST_PERF_CHROME_FRAME_PERFTEST_H_ #include <atlbase.h> -#include "base/perftimer.h" +#include "base/test/perftimer.h" #include "testing/gtest/include/gtest/gtest.h" class SimpleModule : public CAtlExeModuleT<SimpleModule> { diff --git a/components/visitedlink/test/visitedlink_perftest.cc b/components/visitedlink/test/visitedlink_perftest.cc index 9ced41c76..dfc254ff 100644 --- a/components/visitedlink/test/visitedlink_perftest.cc +++ b/components/visitedlink/test/visitedlink_perftest.cc @@ -9,8 +9,8 @@ #include "base/file_util.h" #include "base/files/file_path.h" #include "base/memory/shared_memory.h" -#include "base/perftimer.h" #include "base/strings/stringprintf.h" +#include "base/test/perftimer.h" #include "base/test/test_file_util.h" #include "components/visitedlink/browser/visitedlink_master.h" #include "testing/gtest/include/gtest/gtest.h" diff --git a/content/browser/net/sqlite_persistent_cookie_store_perftest.cc b/content/browser/net/sqlite_persistent_cookie_store_perftest.cc index 4f62706..8c4cb8e 100644 --- a/content/browser/net/sqlite_persistent_cookie_store_perftest.cc +++ b/content/browser/net/sqlite_persistent_cookie_store_perftest.cc @@ -7,10 +7,10 @@ #include "base/bind.h" #include "base/compiler_specific.h" #include "base/files/scoped_temp_dir.h" -#include "base/perftimer.h" #include "base/sequenced_task_runner.h" #include "base/strings/stringprintf.h" #include "base/synchronization/waitable_event.h" +#include "base/test/perftimer.h" #include "base/test/sequenced_worker_pool_owner.h" #include "base/threading/sequenced_worker_pool.h" #include "net/cookies/canonical_cookie.h" diff --git a/ipc/ipc_perftests.cc b/ipc/ipc_perftests.cc index 81adde8..c9891dce 100644 --- a/ipc/ipc_perftests.cc +++ b/ipc/ipc_perftests.cc @@ -10,9 +10,9 @@ #include "base/basictypes.h" #include "base/logging.h" #include "base/memory/scoped_ptr.h" -#include "base/perftimer.h" #include "base/pickle.h" #include "base/strings/stringprintf.h" +#include "base/test/perftimer.h" #include "base/threading/thread.h" #include "base/time/time.h" #include "ipc/ipc_channel.h" diff --git a/media/ffmpeg/ffmpeg_unittest.cc b/media/ffmpeg/ffmpeg_unittest.cc index d774a06..3557ada 100644 --- a/media/ffmpeg/ffmpeg_unittest.cc +++ b/media/ffmpeg/ffmpeg_unittest.cc @@ -17,9 +17,9 @@ #include "base/files/memory_mapped_file.h" #include "base/memory/scoped_ptr.h" #include "base/path_service.h" -#include "base/perftimer.h" #include "base/strings/string_util.h" #include "base/test/perf_test_suite.h" +#include "base/test/perftimer.h" #include "media/base/media.h" #include "media/ffmpeg/ffmpeg_common.h" #include "media/filters/ffmpeg_glue.h" diff --git a/net/cookies/cookie_monster_perftest.cc b/net/cookies/cookie_monster_perftest.cc index c70516f..8187bcb 100644 --- a/net/cookies/cookie_monster_perftest.cc +++ b/net/cookies/cookie_monster_perftest.cc @@ -6,9 +6,9 @@ #include "base/bind.h" #include "base/message_loop/message_loop.h" -#include "base/perftimer.h" #include "base/strings/string_util.h" #include "base/strings/stringprintf.h" +#include "base/test/perftimer.h" #include "net/cookies/canonical_cookie.h" #include "net/cookies/cookie_monster.h" #include "net/cookies/cookie_monster_store_test.h" diff --git a/net/disk_cache/disk_cache_perftest.cc b/net/disk_cache/disk_cache_perftest.cc index f7a1b59..abf39b9 100644 --- a/net/disk_cache/disk_cache_perftest.cc +++ b/net/disk_cache/disk_cache_perftest.cc @@ -8,8 +8,8 @@ #include "base/bind.h" #include "base/bind_helpers.h" #include "base/hash.h" -#include "base/perftimer.h" #include "base/strings/string_util.h" +#include "base/test/perftimer.h" #include "base/test/test_file_util.h" #include "base/threading/thread.h" #include "base/timer/timer.h" diff --git a/net/proxy/dhcp_proxy_script_adapter_fetcher_win_unittest.cc b/net/proxy/dhcp_proxy_script_adapter_fetcher_win_unittest.cc index be177fa..dc00685 100644 --- a/net/proxy/dhcp_proxy_script_adapter_fetcher_win_unittest.cc +++ b/net/proxy/dhcp_proxy_script_adapter_fetcher_win_unittest.cc @@ -4,8 +4,8 @@ #include "net/proxy/dhcp_proxy_script_adapter_fetcher_win.h" -#include "base/perftimer.h" #include "base/synchronization/waitable_event.h" +#include "base/test/perftimer.h" #include "base/test/test_timeouts.h" #include "base/timer/timer.h" #include "net/base/net_errors.h" diff --git a/net/proxy/dhcp_proxy_script_fetcher_win.cc b/net/proxy/dhcp_proxy_script_fetcher_win.cc index 9e34f51..04f0fb0 100644 --- a/net/proxy/dhcp_proxy_script_fetcher_win.cc +++ b/net/proxy/dhcp_proxy_script_fetcher_win.cc @@ -7,7 +7,7 @@ #include "base/bind.h" #include "base/bind_helpers.h" #include "base/metrics/histogram.h" -#include "base/perftimer.h" +#include "base/test/perftimer.h" #include "base/threading/worker_pool.h" #include "net/base/net_errors.h" #include "net/proxy/dhcp_proxy_script_adapter_fetcher_win.h" diff --git a/net/proxy/dhcp_proxy_script_fetcher_win_unittest.cc b/net/proxy/dhcp_proxy_script_fetcher_win_unittest.cc index 919787a..9ef59a4 100644 --- a/net/proxy/dhcp_proxy_script_fetcher_win_unittest.cc +++ b/net/proxy/dhcp_proxy_script_fetcher_win_unittest.cc @@ -9,8 +9,8 @@ #include "base/bind.h" #include "base/bind_helpers.h" #include "base/message_loop/message_loop.h" -#include "base/perftimer.h" #include "base/rand_util.h" +#include "base/test/perftimer.h" #include "base/test/test_timeouts.h" #include "base/threading/platform_thread.h" #include "net/base/completion_callback.h" diff --git a/net/proxy/proxy_resolver_perftest.cc b/net/proxy/proxy_resolver_perftest.cc index 3faf396..bb94ff0 100644 --- a/net/proxy/proxy_resolver_perftest.cc +++ b/net/proxy/proxy_resolver_perftest.cc @@ -6,8 +6,8 @@ #include "base/compiler_specific.h" #include "base/file_util.h" #include "base/path_service.h" -#include "base/perftimer.h" #include "base/strings/string_util.h" +#include "base/test/perftimer.h" #include "net/base/net_errors.h" #include "net/dns/mock_host_resolver.h" #include "net/proxy/proxy_info.h" diff --git a/ppapi/proxy/ppp_messaging_proxy_perftest.cc b/ppapi/proxy/ppp_messaging_proxy_perftest.cc index c52ea11..8520c24 100644 --- a/ppapi/proxy/ppp_messaging_proxy_perftest.cc +++ b/ppapi/proxy/ppp_messaging_proxy_perftest.cc @@ -3,8 +3,8 @@ // found in the LICENSE file. #include "base/command_line.h" -#include "base/perftimer.h" #include "base/strings/string_number_conversions.h" +#include "base/test/perftimer.h" #include "ppapi/c/ppp_messaging.h" #include "ppapi/proxy/ppapi_proxy_test.h" #include "ppapi/proxy/serialized_var.h" diff --git a/tools/gn/secondary/base/test/BUILD.gn b/tools/gn/secondary/base/test/BUILD.gn index 0e097ed..aacb9e1 100644 --- a/tools/gn/secondary/base/test/BUILD.gn +++ b/tools/gn/secondary/base/test/BUILD.gn @@ -4,8 +4,6 @@ static_library("test_support_base") { sources = [ - # TODO(brettw) move this file to this directory. - "../perftimer.cc", "expectations/expectation.cc", "expectations/expectation.h", "expectations/parser.cc", @@ -23,6 +21,7 @@ static_library("test_support_base") { "null_task_runner.h", "perf_test_suite.cc", "perf_test_suite.h", + "perftimer.cc", "scoped_locale.cc", "scoped_locale.h", "scoped_path_override.cc", @@ -108,8 +107,7 @@ config("perf_test_config") { static_library("test_support_perf") { sources = [ - # TODO(brettw) move this file to this directory. - "../perftimer.cc", + "perftimer.cc", "run_all_perftests.cc", ] deps = [ |