OLD | NEW |
1 // Copyright (c) 2015 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2015 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/chromeos/policy/status_uploader.h" | 5 #include "chrome/browser/chromeos/policy/status_uploader.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/prefs/testing_pref_service.h" | |
10 #include "base/test/test_simple_task_runner.h" | 9 #include "base/test/test_simple_task_runner.h" |
11 #include "base/time/time.h" | 10 #include "base/time/time.h" |
12 #include "chrome/browser/chromeos/policy/device_local_account.h" | 11 #include "chrome/browser/chromeos/policy/device_local_account.h" |
13 #include "chrome/browser/chromeos/policy/device_status_collector.h" | 12 #include "chrome/browser/chromeos/policy/device_status_collector.h" |
14 #include "chrome/browser/chromeos/settings/scoped_cros_settings_test_helper.h" | 13 #include "chrome/browser/chromeos/settings/scoped_cros_settings_test_helper.h" |
15 #include "chromeos/settings/cros_settings_names.h" | 14 #include "chromeos/settings/cros_settings_names.h" |
16 #include "components/policy/core/common/cloud/cloud_policy_client.h" | 15 #include "components/policy/core/common/cloud/cloud_policy_client.h" |
17 #include "components/policy/core/common/cloud/mock_cloud_policy_client.h" | 16 #include "components/policy/core/common/cloud/mock_cloud_policy_client.h" |
18 #include "components/policy/core/common/cloud/mock_device_management_service.h" | 17 #include "components/policy/core/common/cloud/mock_device_management_service.h" |
| 18 #include "components/prefs/testing_pref_service.h" |
19 #include "content/public/test/test_browser_thread_bundle.h" | 19 #include "content/public/test/test_browser_thread_bundle.h" |
20 #include "content/public/test/test_utils.h" | 20 #include "content/public/test/test_utils.h" |
21 #include "net/url_request/url_request_context_getter.h" | 21 #include "net/url_request/url_request_context_getter.h" |
22 #include "testing/gmock/include/gmock/gmock.h" | 22 #include "testing/gmock/include/gmock/gmock.h" |
23 #include "testing/gtest/include/gtest/gtest.h" | 23 #include "testing/gtest/include/gtest/gtest.h" |
24 #include "ui/base/user_activity/user_activity_detector.h" | 24 #include "ui/base/user_activity/user_activity_detector.h" |
25 #include "ui/events/platform/platform_event_source.h" | 25 #include "ui/events/platform/platform_event_source.h" |
26 #include "ui/events/platform/platform_event_types.h" | 26 #include "ui/events/platform/platform_event_types.h" |
27 | 27 |
28 #if defined(USE_X11) | 28 #if defined(USE_X11) |
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
254 // Now mock video capture, and no session data should be allowed. | 254 // Now mock video capture, and no session data should be allowed. |
255 MediaCaptureDevicesDispatcher::GetInstance()->OnMediaRequestStateChanged( | 255 MediaCaptureDevicesDispatcher::GetInstance()->OnMediaRequestStateChanged( |
256 0, 0, 0, GURL("http://www.google.com"), | 256 0, 0, 0, GURL("http://www.google.com"), |
257 content::MEDIA_DEVICE_VIDEO_CAPTURE, | 257 content::MEDIA_DEVICE_VIDEO_CAPTURE, |
258 content::MEDIA_REQUEST_STATE_OPENING); | 258 content::MEDIA_REQUEST_STATE_OPENING); |
259 base::RunLoop().RunUntilIdle(); | 259 base::RunLoop().RunUntilIdle(); |
260 EXPECT_FALSE(uploader.IsSessionDataUploadAllowed()); | 260 EXPECT_FALSE(uploader.IsSessionDataUploadAllowed()); |
261 } | 261 } |
262 | 262 |
263 } // namespace policy | 263 } // namespace policy |
OLD | NEW |