/** * @expectedException InvalidArgumentException */ public function testUpdateStreamFail() { $adapter = Mockery::mock('Concrete\\Flysystem\\AdapterInterface'); $adapter->shouldReceive('has')->andReturn(true); $filesystem = new Filesystem($adapter); $filesystem->updateStream('file.txt', 'not a resource'); }