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

Unified Diff: chrome/renderer/spellchecker/spellcheck_unittest.cc

Issue 209193002: Remove PlatformFile from spell checker (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Revert IsEnabled behavior Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/renderer/spellchecker/spellcheck_language.cc ('k') | chrome/renderer/spellchecker/spelling_engine.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/spellchecker/spellcheck_unittest.cc
diff --git a/chrome/renderer/spellchecker/spellcheck_unittest.cc b/chrome/renderer/spellchecker/spellcheck_unittest.cc
index 05f0b6b571d9d3c1d265955625107edfa51fc33d..6765703132c7d5984b089611802f814821c9564b 100644
--- a/chrome/renderer/spellchecker/spellcheck_unittest.cc
+++ b/chrome/renderer/spellchecker/spellcheck_unittest.cc
@@ -55,17 +55,17 @@ class SpellCheckTest : public testing::Test {
void InitializeSpellCheck(const std::string& language) {
base::FilePath hunspell_directory = GetHunspellDirectory();
EXPECT_FALSE(hunspell_directory.empty());
- base::PlatformFile file = base::CreatePlatformFile(
+ base::File file(
chrome::spellcheck_common::GetVersionedFileName(language,
- hunspell_directory),
- base::PLATFORM_FILE_OPEN | base::PLATFORM_FILE_READ, NULL, NULL);
+ hunspell_directory),
+ base::File::FLAG_OPEN | base::File::FLAG_READ);
#if defined(OS_MACOSX)
// TODO(groby): Forcing spellcheck to use hunspell, even on OSX.
// Instead, tests should exercise individual spelling engines.
spell_check_->spellcheck_.platform_spelling_engine_.reset(
new HunspellEngine);
#endif
- spell_check_->Init(file, std::set<std::string>(), language);
+ spell_check_->Init(file.Pass(), std::set<std::string>(), language);
}
void EnableAutoCorrect(bool enable_autocorrect) {
« no previous file with comments | « chrome/renderer/spellchecker/spellcheck_language.cc ('k') | chrome/renderer/spellchecker/spelling_engine.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698