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

Side by Side Diff: chrome/browser/ui/webui/signin/signin_create_profile_handler_unittest.cc

Issue 2130453004: [Sync] Move //sync to //components/sync. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 4 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/ui/webui/signin/signin_create_profile_handler.h" 5 #include "chrome/browser/ui/webui/signin/signin_create_profile_handler.h"
6 6
7 #include "base/strings/utf_string_conversions.h" 7 #include "base/strings/utf_string_conversions.h"
8 #include "chrome/browser/prefs/browser_prefs.h" 8 #include "chrome/browser/prefs/browser_prefs.h"
9 #include "chrome/browser/profiles/profile.h" 9 #include "chrome/browser/profiles/profile.h"
10 #include "chrome/browser/profiles/profile_attributes_entry.h" 10 #include "chrome/browser/profiles/profile_attributes_entry.h"
11 #include "chrome/browser/profiles/profile_attributes_storage.h" 11 #include "chrome/browser/profiles/profile_attributes_storage.h"
12 #include "chrome/browser/profiles/profile_avatar_icon_util.h" 12 #include "chrome/browser/profiles/profile_avatar_icon_util.h"
13 #include "chrome/browser/signin/fake_signin_manager_builder.h" 13 #include "chrome/browser/signin/fake_signin_manager_builder.h"
14 #include "chrome/browser/signin/signin_error_controller_factory.h" 14 #include "chrome/browser/signin/signin_error_controller_factory.h"
15 #include "chrome/browser/signin/signin_manager_factory.h" 15 #include "chrome/browser/signin/signin_manager_factory.h"
16 #include "chrome/common/pref_names.h" 16 #include "chrome/common/pref_names.h"
17 #include "chrome/grit/generated_resources.h" 17 #include "chrome/grit/generated_resources.h"
18 #include "chrome/test/base/browser_with_test_window_test.h" 18 #include "chrome/test/base/browser_with_test_window_test.h"
19 #include "chrome/test/base/testing_browser_process.h" 19 #include "chrome/test/base/testing_browser_process.h"
20 #include "chrome/test/base/testing_profile_manager.h" 20 #include "chrome/test/base/testing_profile_manager.h"
21 #include "components/signin/core/browser/fake_auth_status_provider.h" 21 #include "components/signin/core/browser/fake_auth_status_provider.h"
22 #include "components/sync/api/fake_sync_change_processor.h"
23 #include "components/sync/api/sync_data.h"
24 #include "components/sync/api/sync_error_factory_mock.h"
25 #include "components/sync/core/attachments/attachment_service_proxy_for_test.h"
26 #include "components/sync/protocol/sync.pb.h"
22 #include "components/syncable_prefs/testing_pref_service_syncable.h" 27 #include "components/syncable_prefs/testing_pref_service_syncable.h"
23 #include "content/public/test/test_web_ui.h" 28 #include "content/public/test/test_web_ui.h"
24 #include "sync/api/fake_sync_change_processor.h"
25 #include "sync/api/sync_data.h"
26 #include "sync/api/sync_error_factory_mock.h"
27 #include "sync/internal_api/public/attachments/attachment_service_proxy_for_test .h"
28 #include "sync/protocol/sync.pb.h"
29 #include "testing/gmock/include/gmock/gmock.h" 29 #include "testing/gmock/include/gmock/gmock.h"
30 #include "testing/gtest/include/gtest/gtest.h" 30 #include "testing/gtest/include/gtest/gtest.h"
31 #include "ui/base/l10n/l10n_util.h" 31 #include "ui/base/l10n/l10n_util.h"
32 32
33 #if defined(ENABLE_SUPERVISED_USERS) 33 #if defined(ENABLE_SUPERVISED_USERS)
34 #include "chrome/browser/supervised_user/legacy/supervised_user_sync_service.h" 34 #include "chrome/browser/supervised_user/legacy/supervised_user_sync_service.h"
35 #include "chrome/browser/supervised_user/legacy/supervised_user_sync_service_fac tory.h" 35 #include "chrome/browser/supervised_user/legacy/supervised_user_sync_service_fac tory.h"
36 #endif 36 #endif
37 37
38 // Gmock matchers and actions. 38 // Gmock matchers and actions.
(...skipping 558 matching lines...) Expand 10 before | Expand all | Expand 10 after
597 EXPECT_EQ("create-profile-error", callback_name); 597 EXPECT_EQ("create-profile-error", callback_name);
598 598
599 base::string16 expected_error_message = l10n_util::GetStringUTF16( 599 base::string16 expected_error_message = l10n_util::GetStringUTF16(
600 IDS_PROFILES_CREATE_SUPERVISED_NOT_ALLOWED_BY_POLICY); 600 IDS_PROFILES_CREATE_SUPERVISED_NOT_ALLOWED_BY_POLICY);
601 base::string16 error_message; 601 base::string16 error_message;
602 ASSERT_TRUE(web_ui()->call_data()[0]->arg2()->GetAsString(&error_message)); 602 ASSERT_TRUE(web_ui()->call_data()[0]->arg2()->GetAsString(&error_message));
603 EXPECT_EQ(expected_error_message, error_message); 603 EXPECT_EQ(expected_error_message, error_message);
604 } 604 }
605 605
606 #endif 606 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698