Index: chrome/browser/chromeos/app_mode/kiosk_app_manager.cc |
diff --git a/chrome/browser/chromeos/app_mode/kiosk_app_manager.cc b/chrome/browser/chromeos/app_mode/kiosk_app_manager.cc |
index d3c295f20e146146666ee965fa7aaa8f7d59dc8d..59ae97350a0c87cb6ef0715e875c199de3df251b 100644 |
--- a/chrome/browser/chromeos/app_mode/kiosk_app_manager.cc |
+++ b/chrome/browser/chromeos/app_mode/kiosk_app_manager.cc |
@@ -238,6 +238,22 @@ void KioskAppManager::InitSession(Profile* profile, |
app_session_->Init(profile, app_id); |
} |
+void KioskAppManager::AddAppForTest( |
+ const std::string& app_id, |
+ const AccountId& account_id, |
+ const GURL& update_url, |
+ const std::string& required_platform_version) { |
+ for (auto it = apps_.begin(); it != apps_.end(); ++it) { |
+ if ((*it)->app_id() == app_id) { |
+ apps_.erase(it); |
+ break; |
+ } |
+ } |
+ |
+ apps_.emplace_back(KioskAppData::CreateForTest( |
+ this, app_id, account_id, update_url, required_platform_version)); |
+} |
+ |
void KioskAppManager::EnableConsumerKioskAutoLaunch( |
const KioskAppManager::EnableKioskAutoLaunchCallback& callback) { |
policy::BrowserPolicyConnectorChromeOS* connector = |