src/Console/DuskCommand.php
protected function purgeScreenshots()
    {
        $path = base_path('tests/Browser/screenshots');

        if (! is_dir($path)) {
            return;
        }

        $files = Finder::create()->files()
                        ->in($path)
                        ->name('failure-*');

        foreach ($files as $file) {
            @unlink($file->getRealPath());
        }
    }
protected function purgeScreenshots()
    {
        $path = base_path('tests/Browser/screenshots');

        if (! is_dir($path)) {
            return;
        }

        $files = Finder::create()->files()
                        ->in($path)
                        ->name('failure-*');

        foreach ($files as $file) {
            @unlink($file->getRealPath());
        }
    }
protected function purgeScreenshots ( ) { $ path = base_path ( 'tests/Browser/screenshots' ) ; if ( ! is_dir ( $ path ) ) { return ; } $ files = Finder :: create ( ) -> files ( ) -> in ( $ path ) -> name ( 'failure-*' ) ; foreach ( $ files as $ file ) { @ unlink ( $ file -> getRealPath ( ) ) ; } }
Purge the failure screenshots.

@return void
Purge the failure screenshots .