We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cb6a9f4 commit 29f6ab7Copy full SHA for 29f6ab7
1 file changed
tests/test-cli.php
@@ -44,6 +44,9 @@ function test_encoded_string_pad() {
44
$this->assertEquals( 7, strlen( \cli\Colors::pad( 'óra', 6 ) ) ); // special characters take one byte
45
$this->assertEquals( 9, strlen( \cli\Colors::pad( '日本語', 6 ) ) ); // each character takes two bytes
46
$this->assertEquals( 17, strlen( \cli\Colors::pad( 'עִבְרִית', 6 ) ) ); // process Hebrew vowels
47
+ $this->assertEquals( 6, strlen( \cli\Colors::pad( 'hello', 6, false, false, STR_PAD_RIGHT ) ) );
48
+ $this->assertEquals( 7, strlen( \cli\Colors::pad( 'óra', 6, false, false, STR_PAD_LEFT ) ) ); // special characters take one byte
49
+ $this->assertEquals( 9, strlen( \cli\Colors::pad( '日本語', 6, false, false, STR_PAD_BOTH ) ) ); // each character takes two bytes
50
}
51
52
function test_colorized_string_pad() {
0 commit comments