You are here

public function vfsStreamBlockTestCase::addStructure in Zircon Profile 8

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

tests adding a complex structure

@test

File

vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamBlockTestCase.php, line 59

Class

vfsStreamBlockTestCase
Test for org\bovigo\vfs\vfsStreamBlock.

Namespace

org\bovigo\vfs

Code

public function addStructure() {
  $structure = array(
    'topLevel' => array(
      'thisIsAFile' => 'file contents',
      '[blockDevice]' => 'block contents',
    ),
  );
  $root = vfsStream::create($structure);
  $this
    ->assertSame('block', filetype(vfsStream::url('root/topLevel/blockDevice')));
}