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

Side by Side Diff: snapshot/test/test_process_snapshot.cc

Issue 1000263003: Add MinidumpCrashpadInfo::report_id (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@master
Patch Set: Created 5 years, 9 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 | « snapshot/test/test_process_snapshot.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Crashpad Authors. All rights reserved. 1 // Copyright 2014 The Crashpad Authors. All rights reserved.
2 // 2 //
3 // Licensed under the Apache License, Version 2.0 (the "License"); 3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License. 4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at 5 // You may obtain a copy of the License at
6 // 6 //
7 // http://www.apache.org/licenses/LICENSE-2.0 7 // http://www.apache.org/licenses/LICENSE-2.0
8 // 8 //
9 // Unless required by applicable law or agreed to in writing, software 9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS, 10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and 12 // See the License for the specific language governing permissions and
13 // limitations under the License. 13 // limitations under the License.
14 14
15 #include "snapshot/exception_snapshot.h" 15 #include "snapshot/exception_snapshot.h"
16 #include "snapshot/system_snapshot.h" 16 #include "snapshot/system_snapshot.h"
17 #include "snapshot/test/test_process_snapshot.h" 17 #include "snapshot/test/test_process_snapshot.h"
18 18
19 namespace crashpad { 19 namespace crashpad {
20 namespace test { 20 namespace test {
21 21
22 TestProcessSnapshot::TestProcessSnapshot() 22 TestProcessSnapshot::TestProcessSnapshot()
23 : process_id_(0), 23 : process_id_(0),
24 parent_process_id_(0), 24 parent_process_id_(0),
25 snapshot_time_(), 25 snapshot_time_(),
26 process_start_time_(), 26 process_start_time_(),
27 process_cpu_user_time_(), 27 process_cpu_user_time_(),
28 process_cpu_system_time_(), 28 process_cpu_system_time_(),
29 report_id_(),
29 client_id_(), 30 client_id_(),
30 annotations_simple_map_(), 31 annotations_simple_map_(),
31 system_(), 32 system_(),
32 threads_(), 33 threads_(),
33 modules_(), 34 modules_(),
34 exception_() { 35 exception_() {
35 } 36 }
36 37
37 TestProcessSnapshot::~TestProcessSnapshot() { 38 TestProcessSnapshot::~TestProcessSnapshot() {
38 } 39 }
(...skipping 13 matching lines...) Expand all
52 void TestProcessSnapshot::ProcessStartTime(timeval* start_time) const { 53 void TestProcessSnapshot::ProcessStartTime(timeval* start_time) const {
53 *start_time = process_start_time_; 54 *start_time = process_start_time_;
54 } 55 }
55 56
56 void TestProcessSnapshot::ProcessCPUTimes(timeval* user_time, 57 void TestProcessSnapshot::ProcessCPUTimes(timeval* user_time,
57 timeval* system_time) const { 58 timeval* system_time) const {
58 *user_time = process_cpu_user_time_; 59 *user_time = process_cpu_user_time_;
59 *system_time = process_cpu_system_time_; 60 *system_time = process_cpu_system_time_;
60 } 61 }
61 62
63 void TestProcessSnapshot::ReportID(UUID* report_id) const {
64 *report_id = report_id_;
65 }
66
62 void TestProcessSnapshot::ClientID(UUID* client_id) const { 67 void TestProcessSnapshot::ClientID(UUID* client_id) const {
63 *client_id = client_id_; 68 *client_id = client_id_;
64 } 69 }
65 70
66 const std::map<std::string, std::string>& 71 const std::map<std::string, std::string>&
67 TestProcessSnapshot::AnnotationsSimpleMap() const { 72 TestProcessSnapshot::AnnotationsSimpleMap() const {
68 return annotations_simple_map_; 73 return annotations_simple_map_;
69 } 74 }
70 75
71 const SystemSnapshot* TestProcessSnapshot::System() const { 76 const SystemSnapshot* TestProcessSnapshot::System() const {
(...skipping 15 matching lines...) Expand all
87 } 92 }
88 return modules; 93 return modules;
89 } 94 }
90 95
91 const ExceptionSnapshot* TestProcessSnapshot::Exception() const { 96 const ExceptionSnapshot* TestProcessSnapshot::Exception() const {
92 return exception_.get(); 97 return exception_.get();
93 } 98 }
94 99
95 } // namespace test 100 } // namespace test
96 } // namespace crashpad 101 } // namespace crashpad
OLDNEW
« no previous file with comments | « snapshot/test/test_process_snapshot.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698