diff options
author | hbono@chromium.org <hbono@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-08-14 12:19:03 +0000 |
---|---|---|
committer | hbono@chromium.org <hbono@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-08-14 12:19:03 +0000 |
commit | e8ba2059d133c3450f602ea89b17e049ea23de59 (patch) | |
tree | c3f77387025ca16774ba2b0634f331714f990b84 /chrome/browser/spellcheck_unittest.cc | |
parent | 747d87bbdce352a14e267d448e8502f262e31cc7 (diff) | |
download | chromium_src-e8ba2059d133c3450f602ea89b17e049ea23de59.zip chromium_src-e8ba2059d133c3450f602ea89b17e049ea23de59.tar.gz chromium_src-e8ba2059d133c3450f602ea89b17e049ea23de59.tar.bz2 |
A fix for a unit-test break on Mac.
This change fixes my new unit-test "SpellCheckTest.SpellCheckTest" breaks on Mac.
The system dictionaries of Mac spellchecker don't have the following words included in hunspell:
* en-AU (Australia): "organize" (which is a typo of "organise");
* en-GB (United Kingdom): "organize" (which is a typo of "organise");
* pt-BT (Brazil): "Google";
* pt-PT (Portugal): "Google".
This change removed "Google" from a couple of texts and fixed a couple of typos. Also, this change adds a language for Spanish (Spain), which I forgot adding.
TBR=brettw
BUG=18184
TEST=run unit_tests on Mac
Review URL: http://codereview.chromium.org/164553
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23431 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/spellcheck_unittest.cc')
-rw-r--r-- | chrome/browser/spellcheck_unittest.cc | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/chrome/browser/spellcheck_unittest.cc b/chrome/browser/spellcheck_unittest.cc index ddaa79f..c4823d5 100644 --- a/chrome/browser/spellcheck_unittest.cc +++ b/chrome/browser/spellcheck_unittest.cc @@ -700,13 +700,13 @@ TEST_F(SpellCheckTest, SpellCheckText) { // English (Australia) "en-AU", // L"Google's " - to be added. - L"mission is to organize the world's information and make it " + L"mission is to organise the world's information and make it " L"universally accessible and useful." }, { // English (United Kingdom) "en-GB", // L"Google's " - to be added. - L"mission is to organize the world's information and make it " + L"mission is to organise the world's information and make it " L"universally accessible and useful." }, { // English (United States) @@ -716,7 +716,9 @@ TEST_F(SpellCheckTest, SpellCheckText) { }, { // Spanish "es-ES", - L"La misi\x00F3n de Google es organizar la informaci\x00F3n mundial " + L"La misi\x00F3n de " + // L"Google" - to be added. + L" es organizar la informaci\x00F3n mundial " L"para que resulte universalmente accesible y \x00FAtil." }, { // Estonian @@ -801,14 +803,18 @@ TEST_F(SpellCheckTest, SpellCheckText) { }, { // Portuguese (Brazil) "pt-BR", - L"A miss\x00E3o do Google \x00E9 organizar as informa\x00E7\x00F5" + L"A miss\x00E3o do " + // L"Google " - to be added. + L"\x00E9 organizar as informa\x00E7\x00F5" L"es do mundo todo e torn\x00E1-las acess\x00EDveis e " // L"\x00FAteis " - to be added. L"em car\x00E1ter universal." }, { // Portuguese (Portugal) "pt-PT", - L"O Google tem por miss\x00E3o organizar a informa\x00E7\x00E3o do " + L"O " + // L"Google " - to be added. + L"tem por miss\x00E3o organizar a informa\x00E7\x00E3o do " L"mundo e torn\x00E1-la universalmente acess\x00EDvel e \x00FAtil" }, { // Romanian @@ -840,7 +846,7 @@ TEST_F(SpellCheckTest, SpellCheckText) { L"aby boli v\x0161eobecne dostupn\x00E9 a u\x017Eito\x010Dn\x00E9." }, { // Slovenian - "sl-SL", + "sl-SI", // L"Googlovo " - to be added. L"poslanstvo je organizirati svetovne informacije in " L"omogo\x010Diti njihovo dostopnost in s tem uporabnost za vse." @@ -871,6 +877,7 @@ TEST_F(SpellCheckTest, SpellCheckText) { ASSERT_FALSE(hunspell_directory.empty()); for (size_t i = 0; i < ARRAYSIZE_UNSAFE(kTestCases); ++i) { + fprintf(stderr, "%s(): %s\n", __FUNCTION__, kTestCases[i].language); scoped_refptr<SpellChecker> spell_checker(new SpellChecker( hunspell_directory, kTestCases[i].language, NULL, FilePath())); @@ -885,7 +892,7 @@ TEST_F(SpellCheckTest, SpellCheckText) { &misspelling_start, &misspelling_length, NULL); - EXPECT_EQ(true, result); + EXPECT_EQ(true, result) << kTestCases[i].language; EXPECT_EQ(0, misspelling_start); EXPECT_EQ(0, misspelling_length); } |