File: 004.phpt

package info (click to toggle)
php-pspell 3%3A1.0.1-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 172 kB
  • sloc: ansic: 571; xml: 57; php: 36; makefile: 3
file content (33 lines) | stat: -rw-r--r-- 628 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
--TEST--
pspell configs
--EXTENSIONS--
pspell
--SKIPIF--
<?php
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'));

?>
--EXPECT--
bool(true)
bool(true)
bool(false)
---
bool(true)
bool(true)