X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Fchrome%2Fbrowser%2Fchromeos%2Fpolicy%2Fdevice_status_collector_browsertest.cc;h=985350eeee967dbd47206521ca5d423a7fa274ee;hb=004985e17e624662a4c85c76a7654039dc83f028;hp=b2f62e98b9afe26c2b04f77e293308c5025e90a9;hpb=2f108dbacb161091e42a3479f4e171339b7e7623;p=platform%2Fframework%2Fweb%2Fcrosswalk.git diff --git a/src/chrome/browser/chromeos/policy/device_status_collector_browsertest.cc b/src/chrome/browser/chromeos/policy/device_status_collector_browsertest.cc index b2f62e9..985350e 100644 --- a/src/chrome/browser/chromeos/policy/device_status_collector_browsertest.cc +++ b/src/chrome/browser/chromeos/policy/device_status_collector_browsertest.cc @@ -152,6 +152,10 @@ class DeviceStatusCollectorTest : public testing::Test { : ui_thread_(content::BrowserThread::UI, &message_loop_), file_thread_(content::BrowserThread::FILE, &message_loop_), io_thread_(content::BrowserThread::IO, &message_loop_), + install_attributes_("managed.com", + "user@managed.com", + "device_id", + DEVICE_MODE_ENTERPRISE), user_manager_(new chromeos::MockUserManager()), user_manager_enabler_(user_manager_) { // Run this test with a well-known timezone so that Time::LocalMidnight() @@ -173,13 +177,6 @@ class DeviceStatusCollectorTest : public testing::Test { cros_settings_->RemoveSettingsProvider(device_settings_provider_)); cros_settings_->AddSettingsProvider(&stub_settings_provider_); - // Set up fake install attributes. - StubEnterpriseInstallAttributes* attributes = - new StubEnterpriseInstallAttributes(); - attributes->SetDomain("managed.com"); - attributes->SetRegistrationUser("user@managed.com"); - BrowserPolicyConnectorChromeOS::SetInstallAttributesForTesting(attributes); - RestartStatusCollector(); } @@ -261,6 +258,7 @@ class DeviceStatusCollectorTest : public testing::Test { content::TestBrowserThread file_thread_; content::TestBrowserThread io_thread_; + ScopedStubEnterpriseInstallAttributes install_attributes_; TestingPrefServiceSimple prefs_; chromeos::system::MockStatisticsProvider statistics_provider_; chromeos::ScopedTestDeviceSettingsService test_device_settings_service_;