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

Side by Side Diff: chrome/browser/metrics/metrics_service_unittest.cc

Issue 8501005: Include PPAPI plugin crashes in the plugin crash data. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Include PPAPI plugin crash info the plugin crash elements on all platforms. Created 9 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/metrics/metrics_service.cc ('k') | content/browser/ppapi_plugin_process_host.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/metrics/metrics_service.h" 5 #include "chrome/browser/metrics/metrics_service.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/base64.h" 9 #include "base/base64.h"
10 10
(...skipping 10 matching lines...) Expand all
21 for (uint32 i = 0; i < clientid.length(); i++) { 21 for (uint32 i = 0; i < clientid.length(); i++) {
22 char current = clientid.at(i); 22 char current = clientid.at(i);
23 if (i == 8 || i == 13 || i == 18 || i == 23) { 23 if (i == 8 || i == 13 || i == 18 || i == 23) {
24 EXPECT_EQ('-', current); 24 EXPECT_EQ('-', current);
25 } else { 25 } else {
26 EXPECT_TRUE(std::string::npos != hexchars.find(current)); 26 EXPECT_TRUE(std::string::npos != hexchars.find(current));
27 } 27 }
28 } 28 }
29 } 29 }
30 30
31 TEST(MetricsServiceTest, IsPluginProcess) {
32 EXPECT_TRUE(
33 MetricsService::IsPluginProcess(ChildProcessInfo::PLUGIN_PROCESS));
34 EXPECT_TRUE(
35 MetricsService::IsPluginProcess(ChildProcessInfo::PPAPI_PLUGIN_PROCESS));
36 EXPECT_FALSE(
37 MetricsService::IsPluginProcess(ChildProcessInfo::GPU_PROCESS));
38 }
OLDNEW
« no previous file with comments | « chrome/browser/metrics/metrics_service.cc ('k') | content/browser/ppapi_plugin_process_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698