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

Side by Side Diff: content/test/test_power_data_provider.cc

Issue 140583003: Chrome power profiler service (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 6 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
OLDNEW
(Empty)
1 // Copyright (c) 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "content/test/test_power_data_provider.h"
6
7 namespace content {
8
9 bool TestPowerDataProvider::GetData(PowerEvent* event) {
10 if (event_number_ == 0)
11 return false;
12
13 event->type = PowerEvent::SOC_PACKAGE;
14 event->time = base::TimeTicks::Now();
15 event->value = 1.0;
16 event_number_--;
17 return true;
18 }
19
20 TestPowerDataProvider::TestPowerDataProvider(int count)
21 : event_number_(count) {
22 }
23
24 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698