1--TEST--
2IntlBreakIterator::getPartsIterator(): argument variations
3--SKIPIF--
4<?php
5if (!extension_loaded('intl'))
6	die('skip intl extension not enabled');
7--FILE--
8<?php
9ini_set("intl.error_level", E_WARNING);
10ini_set("intl.default_locale", "pt_PT");
11
12$text = 'foo bar tao';
13
14$it = IntlBreakIterator::createWordInstance(NULL);
15$it->setText($text);
16
17var_dump(iterator_to_array($it->getPartsIterator(IntlPartsIterator::KEY_SEQUENTIAL)));
18var_dump(iterator_to_array($it->getPartsIterator(IntlPartsIterator::KEY_LEFT)));
19var_dump(iterator_to_array($it->getPartsIterator(IntlPartsIterator::KEY_RIGHT)));
20
21?>
22==DONE==
23--EXPECT--
24array(5) {
25  [0]=>
26  string(3) "foo"
27  [1]=>
28  string(1) " "
29  [2]=>
30  string(3) "bar"
31  [3]=>
32  string(1) " "
33  [4]=>
34  string(3) "tao"
35}
36array(5) {
37  [0]=>
38  string(3) "foo"
39  [4]=>
40  string(1) " "
41  [5]=>
42  string(3) "bar"
43  [8]=>
44  string(1) " "
45  [9]=>
46  string(3) "tao"
47}
48array(5) {
49  [3]=>
50  string(3) "foo"
51  [5]=>
52  string(1) " "
53  [8]=>
54  string(3) "bar"
55  [9]=>
56  string(1) " "
57  [12]=>
58  string(3) "tao"
59}
60==DONE==
61