public function testIfClearCleansDirectory() { $fs = m::mock('Illuminate\\Filesystem\\Filesystem'); $fs->shouldReceive('cleanDirectory')->once()->with($dir = '_static'); $cleaner = new Cleaner($dir, $fs); $cleaner->clear(); }
/** * Execute the console command. * * @return void */ public function fire() { $this->cleaner->clear(); $this->info('Static files were deleted'); }