Fakerino\DataSource\FakeFileContainer::add PHP Method

add() public static method

Adds a file to the container.
public static add ( string $name, File $file )
$name string
$file Fakerino\DataSource\File\File
    public static function add($name, File $file)
    {
        self::$files[$name] = $file;
    }

Usage Example

 public function testAddMethod()
 {
     $container = new FakeFileContainer();
     $file = new File($this->filePath);
     $container->add('file', $file);
     $this->assertInstanceOf('\\SplFileInfo', $container->get($this->filePath));
 }
All Usage Examples Of Fakerino\DataSource\FakeFileContainer::add
FakeFileContainer