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

Side by Side Diff: chrome/browser/chromeos/login/screens/device_disabled_screen_unittest.cc

Issue 672233002: ScreenObserver::(Set|Get)UsageStatisticsReporting() are extracted into EulaScreen::Delegate. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 6 years, 2 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 | « no previous file | chrome/browser/chromeos/login/screens/eula_screen.h » ('j') | 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 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 "chrome/browser/chromeos/login/screens/device_disabled_screen.h" 5 #include "chrome/browser/chromeos/login/screens/device_disabled_screen.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/prefs/scoped_user_pref_update.h" 10 #include "base/prefs/scoped_user_pref_update.h"
(...skipping 29 matching lines...) Expand all
40 40
41 // testing::Test: 41 // testing::Test:
42 void SetUp() override; 42 void SetUp() override;
43 void TearDown() override; 43 void TearDown() override;
44 44
45 // ScreenObserver: 45 // ScreenObserver:
46 MOCK_METHOD1(OnExit, void(ExitCodes)); 46 MOCK_METHOD1(OnExit, void(ExitCodes));
47 void ShowCurrentScreen() override; 47 void ShowCurrentScreen() override;
48 void OnSetUserNamePassword(const std::string& username, 48 void OnSetUserNamePassword(const std::string& username,
49 const std::string& password) override; 49 const std::string& password) override;
50 void SetUsageStatisticsReporting(bool val) override;
51 bool GetUsageStatisticsReporting() const override;
52 void SetHostConfiguration() override; 50 void SetHostConfiguration() override;
53 void ConfigureHost(bool accepted_eula, 51 void ConfigureHost(bool accepted_eula,
54 const std::string& lang, 52 const std::string& lang,
55 const std::string& timezone, 53 const std::string& timezone,
56 bool send_reports, 54 bool send_reports,
57 const std::string& keyboard_layout) override; 55 const std::string& keyboard_layout) override;
58 ErrorScreen* GetErrorScreen() override; 56 ErrorScreen* GetErrorScreen() override;
59 void ShowErrorScreen() override; 57 void ShowErrorScreen() override;
60 void HideErrorScreen(BaseScreen* parent_screen) override; 58 void HideErrorScreen(BaseScreen* parent_screen) override;
61 59
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 } 95 }
98 96
99 void DeviceDisabledScreenTest::ShowCurrentScreen() { 97 void DeviceDisabledScreenTest::ShowCurrentScreen() {
100 } 98 }
101 99
102 void DeviceDisabledScreenTest::OnSetUserNamePassword( 100 void DeviceDisabledScreenTest::OnSetUserNamePassword(
103 const std::string& username, 101 const std::string& username,
104 const std::string& password) { 102 const std::string& password) {
105 } 103 }
106 104
107 void DeviceDisabledScreenTest::SetUsageStatisticsReporting(bool val) {
108 }
109
110 bool DeviceDisabledScreenTest::GetUsageStatisticsReporting() const {
111 return false;
112 }
113
114 void DeviceDisabledScreenTest::SetHostConfiguration() { 105 void DeviceDisabledScreenTest::SetHostConfiguration() {
115 } 106 }
116 107
117 void DeviceDisabledScreenTest::ConfigureHost( 108 void DeviceDisabledScreenTest::ConfigureHost(
118 bool accepted_eula, 109 bool accepted_eula,
119 const std::string& lang, 110 const std::string& lang,
120 const std::string& timezone, 111 const std::string& timezone,
121 bool send_reports, 112 bool send_reports,
122 const std::string& keyboard_layout) { 113 const std::string& keyboard_layout) {
123 } 114 }
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
205 // Verifies that the device disabled screen is shown when the device is marked 196 // Verifies that the device disabled screen is shown when the device is marked
206 // as disabled, device disabling is not turned off by flag and the device is not 197 // as disabled, device disabling is not turned off by flag and the device is not
207 // owned yet. 198 // owned yet.
208 TEST_F(DeviceDisabledScreenTest, ShowWhenDisabledAndNotOwned) { 199 TEST_F(DeviceDisabledScreenTest, ShowWhenDisabledAndNotOwned) {
209 SetDeviceDisabled(true); 200 SetDeviceDisabled(true);
210 ExpectScreenToShow(); 201 ExpectScreenToShow();
211 TryToShowScreen(); 202 TryToShowScreen();
212 } 203 }
213 204
214 } // namespace chromeos 205 } // namespace chromeos
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/screens/eula_screen.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698