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

Unified Diff: device/vr/vr_service_impl_unittest.cc

Issue 2471433002: Implement WebVR presentation pausing for VR Shell Menu Mode (Closed)
Patch Set: Add comments to VRDisplay Created 4 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 side-by-side diff with in-line comments
Download patch
Index: device/vr/vr_service_impl_unittest.cc
diff --git a/device/vr/vr_service_impl_unittest.cc b/device/vr/vr_service_impl_unittest.cc
index f0b8ce276d60365dc478b19496d4744c5d9a72f4..ca1b7edffb96976584b5a2d0ab395c54e62aa87d 100644
--- a/device/vr/vr_service_impl_unittest.cc
+++ b/device/vr/vr_service_impl_unittest.cc
@@ -4,6 +4,7 @@
#include "device/vr/vr_service_impl.h"
+#include "base/memory/ref_counted.h"
#include "base/message_loop/message_loop.h"
#include "base/run_loop.h"
#include "device/vr/test/fake_vr_device.h"
@@ -69,9 +70,9 @@ class VRServiceImplTest : public testing::Test {
protected:
void SetUp() override {
- std::unique_ptr<FakeVRDeviceProvider> provider(new FakeVRDeviceProvider());
- provider_ = provider.get();
- device_manager_.reset(new VRDeviceManager(std::move(provider)));
+ FakeVRDeviceProvider* provider = new FakeVRDeviceProvider();
+ provider_ = provider;
+ device_manager_.reset(new VRDeviceManager(provider));
}
void TearDown() override { base::RunLoop().RunUntilIdle(); }
@@ -85,7 +86,7 @@ class VRServiceImplTest : public testing::Test {
size_t ServiceCount() { return device_manager_->services_.size(); }
base::MessageLoop message_loop_;
- FakeVRDeviceProvider* provider_;
+ scoped_refptr<FakeVRDeviceProvider> provider_;
std::unique_ptr<VRDeviceManager> device_manager_;
DISALLOW_COPY_AND_ASSIGN(VRServiceImplTest);

Powered by Google App Engine
This is Rietveld 408576698