I can be really annoying to troubleshoot a failed test in Dusk when using CI systems. What I ended up doing was setting up my project to send these files to S3 on fail. Here are the steps Setup You App This is just S3 storage so make sure you have a bucket and a folder in the bucket to write to. Basically for AWS you make an IAM with a key and secret and let it read/write to this folder.
Just keeping a list of gotchas around dusk. use RefreshDatabase not working Cost: 1 hour lost Basically I had to go back to the slower “use DatabaseMigrations;” otherwise it would not work. The user was null. Links: This thread helped Headless or not Cost: 1 hour lost or less For some odd reasons my tests started coming up blank. I turned off headless in this class DuskTestCase protected function driver() { $args = [ '--disable-gpu', '--headless' ]; if (env("HEADLESS_OFF")) { $args = [ '--disable-gpu' ]; } $options = (new ChromeOptions)->addArguments($args); return RemoteWebDriver::create( 'http://localhost:9515', DesiredCapabilities::chrome()->setCapability( ChromeOptions::CAPABILITY, $options ) ); } And this way it still works on travis.