You are here

public function StringBasedFileContentTestCase::truncateToGreaterSizeAddsZeroBytes in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/StringBasedFileContentTestCase.php \org\bovigo\vfs\content\StringBasedFileContentTestCase::truncateToGreaterSizeAddsZeroBytes()

@test @group issue_33 @since 1.1.0

File

vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/content/StringBasedFileContentTestCase.php, line 211

Class

StringBasedFileContentTestCase
Test for org\bovigo\vfs\content\StringBasedFileContent.

Namespace

org\bovigo\vfs\content

Code

public function truncateToGreaterSizeAddsZeroBytes() {
  $this
    ->assertTrue($this->stringBasedFileContent
    ->truncate(25));
  $this
    ->assertEquals("foobarbaz\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0", $this->stringBasedFileContent
    ->content());
}