| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #import "ios/chrome/browser/ui/settings/translate_collection_view_controller.h" | 5 #import "ios/chrome/browser/ui/settings/translate_collection_view_controller.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 | 8 |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
| 11 #include "base/message_loop/message_loop.h" | 11 #include "base/message_loop/message_loop.h" |
| 12 #include "base/threading/thread_task_runner_handle.h" | 12 #include "base/threading/thread_task_runner_handle.h" |
| 13 #include "components/pref_registry/pref_registry_syncable.h" | 13 #include "components/pref_registry/pref_registry_syncable.h" |
| 14 #include "components/prefs/pref_member.h" | 14 #include "components/prefs/pref_member.h" |
| 15 #include "components/prefs/pref_service.h" | 15 #include "components/prefs/pref_service.h" |
| 16 #include "components/strings/grit/components_locale_settings.h" | 16 #include "components/strings/grit/components_locale_settings.h" |
| 17 #include "components/sync_preferences/pref_service_mock_factory.h" | 17 #include "components/sync_preferences/pref_service_mock_factory.h" |
| 18 #include "components/translate/core/browser/translate_pref_names.h" |
| 18 #include "components/translate/core/browser/translate_prefs.h" | 19 #include "components/translate/core/browser/translate_prefs.h" |
| 19 #include "components/translate/core/common/translate_pref_names.h" | |
| 20 #include "ios/chrome/browser/pref_names.h" | 20 #include "ios/chrome/browser/pref_names.h" |
| 21 #import "ios/chrome/browser/translate/chrome_ios_translate_client.h" | 21 #import "ios/chrome/browser/translate/chrome_ios_translate_client.h" |
| 22 #import "ios/chrome/browser/ui/collection_view/collection_view_controller_test.h
" | 22 #import "ios/chrome/browser/ui/collection_view/collection_view_controller_test.h
" |
| 23 #include "ios/chrome/grit/ios_strings.h" | 23 #include "ios/chrome/grit/ios_strings.h" |
| 24 #include "testing/gtest/include/gtest/gtest.h" | 24 #include "testing/gtest/include/gtest/gtest.h" |
| 25 #import "testing/gtest_mac.h" | 25 #import "testing/gtest_mac.h" |
| 26 #include "testing/platform_test.h" | 26 #include "testing/platform_test.h" |
| 27 #include "ui/base/l10n/l10n_util.h" | 27 #include "ui/base/l10n/l10n_util.h" |
| 28 #include "ui/base/l10n/l10n_util_mac.h" | 28 #include "ui/base/l10n/l10n_util_mac.h" |
| 29 | 29 |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 109 [controller collectionView:[controller collectionView] | 109 [controller collectionView:[controller collectionView] |
| 110 didSelectItemAtIndexPath:[NSIndexPath indexPathForItem:1 inSection:0]]; | 110 didSelectItemAtIndexPath:[NSIndexPath indexPathForItem:1 inSection:0]]; |
| 111 // Check that preferences are gone. | 111 // Check that preferences are gone. |
| 112 EXPECT_FALSE(translate_prefs->IsSiteBlacklisted(kBlacklistedSite)); | 112 EXPECT_FALSE(translate_prefs->IsSiteBlacklisted(kBlacklistedSite)); |
| 113 EXPECT_FALSE(translate_prefs->IsBlockedLanguage(kLanguage1)); | 113 EXPECT_FALSE(translate_prefs->IsBlockedLanguage(kLanguage1)); |
| 114 EXPECT_FALSE( | 114 EXPECT_FALSE( |
| 115 translate_prefs->IsLanguagePairWhitelisted(kLanguage1, kLanguage2)); | 115 translate_prefs->IsLanguagePairWhitelisted(kLanguage1, kLanguage2)); |
| 116 } | 116 } |
| 117 | 117 |
| 118 } // namespace | 118 } // namespace |
| OLD | NEW |