We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
| @@ 191-197 (lines=7) @@ | ||
| 188 | $actual_tokens[ $index ] = $token->with_value( $this->clean_html( $token->value ) ); |
|
| 189 | } |
|
| 190 | ||
| 191 | if ( is_scalar( $expected_value ) ) { |
|
| 192 | if ( false !== strpos( $expected_value, ' ' ) ) { |
|
| 193 | $expected_value = $this->tokenize_sentence( $expected_value ); |
|
| 194 | } else { |
|
| 195 | $expected_value = $this->tokenize( $expected_value ); |
|
| 196 | } |
|
| 197 | } |
|
| 198 | ||
| 199 | // Ensure clean HTML even when a scalar was passed. |
|
| 200 | $this->assertContainsOnlyInstancesOf( \PHP_Typography\Text_Parser\Token::class, $expected_value, '$expected_value has to be a string or an array of tokens.' ); |
|
| @@ 230-234 (lines=5) @@ | ||
| 227 | } |
|
| 228 | ||
| 229 | if ( is_scalar( $expected_value ) ) { |
|
| 230 | if ( false !== strpos( $expected_value, ' ' ) ) { |
|
| 231 | $expected = $this->tokenize_sentence( $expected_value ); |
|
| 232 | } else { |
|
| 233 | $expected = $this->tokenize( $expected_value ); |
|
| 234 | } |
|
| 235 | } else { |
|
| 236 | $this->assertContainsOnlyInstancesOf( \PHP_Typography\Text_Parser\Token::class, $expected_value, '$expected_value has to be a string or an array of tokens.' ); |
|
| 237 | $expected = $expected_value; |
|