diff options
| author | Lorry Tar Creator <lorry-tar-importer@baserock.org> | 2013-03-14 05:42:27 +0000 |
|---|---|---|
| committer | <> | 2013-04-03 16:25:08 +0000 |
| commit | c4dd7a1a684490673e25aaf4fabec5df138854c4 (patch) | |
| tree | 4d57c44caae4480efff02b90b9be86f44bf25409 /ext/pspell/tests/004.phpt | |
| download | php2-master.tar.gz | |
Imported from /home/lorry/working-area/delta_php2/php-5.4.13.tar.bz2.HEADphp-5.4.13master
Diffstat (limited to 'ext/pspell/tests/004.phpt')
| -rw-r--r-- | ext/pspell/tests/004.phpt | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/ext/pspell/tests/004.phpt b/ext/pspell/tests/004.phpt new file mode 100644 index 0000000..80602bc --- /dev/null +++ b/ext/pspell/tests/004.phpt @@ -0,0 +1,35 @@ +--TEST-- +pspell configs +--SKIPIF-- +<?php +if (!extension_loaded('pspell')) die('skip'); +if (!@pspell_new('en')) die('skip English dictionary is not available'); +?> +--FILE-- +<?php + +$cfg = pspell_config_create('en', 'british', '', 'iso8859-1'); +var_dump(pspell_config_mode($cfg, PSPELL_BAD_SPELLERS)); + +var_dump(pspell_config_runtogether($cfg, false)); +$p = pspell_new_config($cfg); +var_dump(pspell_check($p, 'theoasis')); + +echo "---\n"; + +// now it should pass +var_dump(pspell_config_runtogether($cfg, true)); +$p = pspell_new_config($cfg); +var_dump(pspell_check($p, 'theoasis')); + +var_dump(pspell_config_runtogether($cfg, NULL)) + +?> +--EXPECT-- +bool(true) +bool(true) +bool(false) +--- +bool(true) +bool(true) +bool(true) |
