From c6018b85c40299c5913d68a6fc48f25f2dc45f4a Mon Sep 17 00:00:00 2001 From: Marcus Boerger Date: Mon, 25 Jul 2005 18:27:41 +0000 Subject: [PATCH] - Be flexible about spellbook - we want to test the ext not the spell corrections available --- ext/pspell/tests/01pspell_basic.phpt | 32 ++++------------------------ 1 file changed, 4 insertions(+), 28 deletions(-) diff --git a/ext/pspell/tests/01pspell_basic.phpt b/ext/pspell/tests/01pspell_basic.phpt index 37676d087e..1cfb684485 100644 --- a/ext/pspell/tests/01pspell_basic.phpt +++ b/ext/pspell/tests/01pspell_basic.phpt @@ -29,17 +29,13 @@ for($i=0,$u=count($array);$i<$u;++$i) { echo $array[$i].' : '; if (!pspell_check($pspell, $array[$i])) { echo "..false\n"; - $suggestions = pspell_suggest ($pspell, $array[$i]); - - foreach ($suggestions as $suggestion) { - echo "Possible spelling: $suggestion\n"; - } + echo "Possible spellings: " . join(',',pspell_suggest ($pspell, $array[$i])) . "\n"; } else { echo "true\n"; } } ?> ---EXPECT-- +--EXPECTF-- I : true will : true not : true @@ -90,23 +86,7 @@ a : true pack : true Ya : true Seegarets : ..false -Possible spelling: Secrets -Possible spelling: Regrets -Possible spelling: Secretes -Possible spelling: Egrets -Possible spelling: Segre's -Possible spelling: Seagate's -Possible spelling: Regreets -Possible spelling: Segregates -Possible spelling: Sergeants -Possible spelling: Sugariest -Possible spelling: Garrets -Possible spelling: Socrates -Possible spelling: Egret's -Possible spelling: Separates -Possible spelling: Cigarettes -Possible spelling: Sugared -Possible spelling: Scarlets +Possible spellings:%s,Regrets,%s,Cigarettes,%s Ya : true Uh : true My : true @@ -132,9 +112,5 @@ strike : true a : true match : true Ahh : ..false -Possible spelling: Shh -Possible spelling: Ah -Possible spelling: Aha -Possible spelling: Ash -Possible spelling: Ha +Possible spellings:%sAh,Aha,%s matches : true -- 2.50.1