| Index: chrome/browser/web_applications/web_app_mac.mm
|
| diff --git a/chrome/browser/web_applications/web_app_mac.mm b/chrome/browser/web_applications/web_app_mac.mm
|
| index 3a7b237f1f4e34fa21c738e9af121cd5470ece5f..d3d857f426ada0040f6cdfb07ab1bb1086894295 100644
|
| --- a/chrome/browser/web_applications/web_app_mac.mm
|
| +++ b/chrome/browser/web_applications/web_app_mac.mm
|
| @@ -44,6 +44,8 @@
|
| #include "ui/base/resource/resource_bundle.h"
|
| #include "ui/gfx/image/image_family.h"
|
|
|
| +bool g_app_shims_allow_update_and_launch_in_tests = false;
|
| +
|
| namespace {
|
|
|
| // Launch Services Key to run as an agent app, which doesn't launch in the dock.
|
| @@ -854,8 +856,10 @@ base::FilePath GetAppInstallPath(const ShortcutInfo& shortcut_info) {
|
| }
|
|
|
| void MaybeLaunchShortcut(const ShortcutInfo& shortcut_info) {
|
| - if (AppShimsDisabledForTest())
|
| + if (AppShimsDisabledForTest() &&
|
| + !g_app_shims_allow_update_and_launch_in_tests) {
|
| return;
|
| + }
|
|
|
| content::BrowserThread::PostTask(
|
| content::BrowserThread::FILE, FROM_HERE,
|
| @@ -946,8 +950,10 @@ void UpdatePlatformShortcuts(
|
| const ShortcutInfo& shortcut_info,
|
| const extensions::FileHandlersInfo& file_handlers_info) {
|
| DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::FILE));
|
| - if (AppShimsDisabledForTest())
|
| + if (AppShimsDisabledForTest() &&
|
| + !g_app_shims_allow_update_and_launch_in_tests) {
|
| return;
|
| + }
|
|
|
| WebAppShortcutCreator shortcut_creator(
|
| app_data_path, shortcut_info, file_handlers_info);
|
|
|