@@ -42,7 +42,7 @@ discard block |
||
42 | 42 | public function it_can_get_ngram_from_an_array() |
43 | 43 | { |
44 | 44 | $result = [ |
45 | - ['h', 'e'], ['e','l'], ['l','l'], ['l','o'], ['o','h'] |
|
45 | + ['h', 'e'], ['e', 'l'], ['l', 'l'], ['l', 'o'], ['o', 'h'] |
|
46 | 46 | ]; |
47 | 47 | |
48 | 48 | $this->ngramsArray(['h', 'e', 'l', 'l', 'o'], 2)->shouldIterateAs(new \ArrayIterator($result)); |
@@ -51,11 +51,11 @@ discard block |
||
51 | 51 | public function it_can_get_ngram_from_an_array_with_big_n() |
52 | 52 | { |
53 | 53 | $result = [ |
54 | - ['h','e','l','l','o'], |
|
55 | - ['e','l','l','o','h'], |
|
56 | - ['l','l','o','h','e'], |
|
57 | - ['l','o','h','e','l'], |
|
58 | - ['o','h','e','l','l'], |
|
54 | + ['h', 'e', 'l', 'l', 'o'], |
|
55 | + ['e', 'l', 'l', 'o', 'h'], |
|
56 | + ['l', 'l', 'o', 'h', 'e'], |
|
57 | + ['l', 'o', 'h', 'e', 'l'], |
|
58 | + ['o', 'h', 'e', 'l', 'l'], |
|
59 | 59 | ]; |
60 | 60 | |
61 | 61 | $this->ngramsArray(['h', 'e', 'l', 'l', 'o'], 10)->shouldIterateAs(new \ArrayIterator($result)); |
@@ -64,15 +64,15 @@ discard block |
||
64 | 64 | public function it_can_get_ngram_from_an_array_without_cycling() |
65 | 65 | { |
66 | 66 | $result = [ |
67 | - ['h','e','l'], |
|
68 | - ['e','l','l'], |
|
69 | - ['l','l','o'], |
|
70 | - ['l','o',' '], |
|
71 | - ['o',' ','w'], |
|
72 | - [' ','w','o'], |
|
73 | - ['w','o','r'], |
|
74 | - ['o','r','l'], |
|
75 | - ['r','l','d'], |
|
67 | + ['h', 'e', 'l'], |
|
68 | + ['e', 'l', 'l'], |
|
69 | + ['l', 'l', 'o'], |
|
70 | + ['l', 'o', ' '], |
|
71 | + ['o', ' ', 'w'], |
|
72 | + [' ', 'w', 'o'], |
|
73 | + ['w', 'o', 'r'], |
|
74 | + ['o', 'r', 'l'], |
|
75 | + ['r', 'l', 'd'], |
|
76 | 76 | ]; |
77 | 77 | |
78 | 78 | $this->ngramsArray(['h', 'e', 'l', 'l', 'o', ' ', 'w', 'o', 'r', 'l', 'd'], 3, false)->shouldIterateAs(new \ArrayIterator($result)); |