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

Unified Diff: chrome/browser/apps/ephemeral_app_browsertest.cc

Issue 1419823011: app_sorting() calls should go via ExtensionSystem intsead of prefs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Changes as per review comments. Created 5 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/extensions/extension_install_ui_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/apps/ephemeral_app_browsertest.cc
diff --git a/chrome/browser/apps/ephemeral_app_browsertest.cc b/chrome/browser/apps/ephemeral_app_browsertest.cc
index f831a3f57f78e5eadfef32a9a02aa26cccd53875..2204ba60eb96099aa16e5293300518964a823e6e 100644
--- a/chrome/browser/apps/ephemeral_app_browsertest.cc
+++ b/chrome/browser/apps/ephemeral_app_browsertest.cc
@@ -45,6 +45,7 @@
#include "ui/message_center/message_center.h"
#include "ui/message_center/notifier_settings.h"
+using extensions::AppSorting;
using extensions::Event;
using extensions::EventRouter;
using extensions::Extension;
@@ -376,8 +377,7 @@ class EphemeralAppBrowserTest : public EphemeralAppTestBase {
EXPECT_FALSE(sync_change.get());
// Ephemeral apps should not be assigned ordinals.
- extensions::AppSorting* app_sorting =
- ExtensionPrefs::Get(profile())->app_sorting();
+ AppSorting* app_sorting = ExtensionSystem::Get(profile())->app_sorting();
EXPECT_FALSE(app_sorting->GetAppLaunchOrdinal(app_id).IsValid());
EXPECT_FALSE(app_sorting->GetPageOrdinal(app_id).IsValid());
}
@@ -413,7 +413,7 @@ class EphemeralAppBrowserTest : public EphemeralAppTestBase {
Extension::DISABLE_INACTIVE_EPHEMERAL_APP);
// Check sort ordinals.
- extensions::AppSorting* app_sorting = prefs->app_sorting();
+ AppSorting* app_sorting = ExtensionSystem::Get(profile())->app_sorting();
EXPECT_TRUE(app_sorting->GetAppLaunchOrdinal(app_id).IsValid());
EXPECT_TRUE(app_sorting->GetPageOrdinal(app_id).IsValid());
}
@@ -511,8 +511,7 @@ class EphemeralAppBrowserTest : public EphemeralAppTestBase {
VerifyPromotedApp(app_id, expected_set);
// The sort ordinals from sync should not be overridden.
- ExtensionPrefs* prefs = ExtensionPrefs::Get(profile());
- extensions::AppSorting* app_sorting = prefs->app_sorting();
+ AppSorting* app_sorting = ExtensionSystem::Get(profile())->app_sorting();
EXPECT_TRUE(
app_sorting->GetAppLaunchOrdinal(app_id).Equals(kAppLaunchOrdinal));
EXPECT_TRUE(app_sorting->GetPageOrdinal(app_id).Equals(kPageOrdinal));
« no previous file with comments | « no previous file | chrome/browser/extensions/extension_install_ui_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698