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

Side by Side Diff: content/renderer/device_sensors/device_light_event_pump_unittest.cc

Issue 1547073003: Switch to standard integer types in content/renderer/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "device_light_event_pump.h" 5 #include "device_light_event_pump.h"
6 6
7 #include "base/location.h" 7 #include "base/location.h"
8 #include "base/macros.h"
8 #include "base/single_thread_task_runner.h" 9 #include "base/single_thread_task_runner.h"
9 #include "base/thread_task_runner_handle.h" 10 #include "base/thread_task_runner_handle.h"
10 #include "content/common/device_sensors/device_light_hardware_buffer.h" 11 #include "content/common/device_sensors/device_light_hardware_buffer.h"
11 #include "content/public/test/test_utils.h" 12 #include "content/public/test/test_utils.h"
12 #include "testing/gtest/include/gtest/gtest.h" 13 #include "testing/gtest/include/gtest/gtest.h"
13 #include "third_party/WebKit/public/platform/WebDeviceLightListener.h" 14 #include "third_party/WebKit/public/platform/WebDeviceLightListener.h"
14 15
15 namespace content { 16 namespace content {
16 17
17 class MockDeviceLightListener : public blink::WebDeviceLightListener { 18 class MockDeviceLightListener : public blink::WebDeviceLightListener {
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 FROM_HERE, base::Bind(&DeviceLightEventPumpForTesting::FireEvent, 153 FROM_HERE, base::Bind(&DeviceLightEventPumpForTesting::FireEvent,
153 base::Unretained(light_pump()))); 154 base::Unretained(light_pump())));
154 base::MessageLoop::current()->Run(); 155 base::MessageLoop::current()->Run();
155 156
156 // No change in device light as present value is same as previous value. 157 // No change in device light as present value is same as previous value.
157 EXPECT_FALSE(listener()->did_change_device_light()); 158 EXPECT_FALSE(listener()->did_change_device_light());
158 EXPECT_EQ(last_seen_data, static_cast<double>(received_data.value)); 159 EXPECT_EQ(last_seen_data, static_cast<double>(received_data.value));
159 } 160 }
160 161
161 } // namespace content 162 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/device_sensors/device_light_event_pump.h ('k') | content/renderer/device_sensors/device_motion_event_pump.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698