Problem starting chrome driver, php artisan serve and dusk test


#1

I have problem running the dusk test. The chrome driver start , php artisan serve and php artisan dusk all shown Step was canceled. I have tried all the resources and forum to fix this but still no luck, I am stuck here since yesterday. However the built work if I Rebuild with ssh.
You may see the screen-sort below Step was canceled and test stops , however test shows its successful, with green bar. There must be some issue with CI or may be I miss something.

My docker image is circleci/php:7.1.5-browsers and below is my config.yml file setting for installing and running the chrome driver, then running the php dusk test.

- run:
          name: Install Google Chrome
          command: |
            wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
            sudo sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list'
            sudo apt-get update && sudo apt-get install -y google-chrome-stable
            sudo apt-get install -y xvfb
            sudo apt-get -qyy install dbus-x11
            # entry.sh
            sudo rm -f /var/lib/dbus/machine-id
            sudo mkdir -p /var/run/dbus
            sudo service dbus restart
            service dbus status
            export $(dbus-launch)
            export NSS_USE_SHARED_DB=ENABLED
            echo "-- INFO: DBUS_SESSION_BUS_ADDRESS=${DBUS_SESSION_BUS_ADDRESS}"
            #=> e.g. DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-APZO4BE4TJ,guid=6e9c098d053d3038cb0756ae57ecc885
            echo "-- INFO: DBUS_SESSION_BUS_PID=${DBUS_SESSION_BUS_PID}"

      - run:
         name: Start Chrome Driver
         command: ./vendor/laravel/dusk/bin/chromedriver-linux -whitelisted-ips=""
         background: true
      - run:
         name: Run Laravel Server
         command: php artisan serve
         background: true
      - run:
         name: Test 2 - Run Laravel Desk for Browser Testing
         command: php artisan dusk

#2

This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.