How Can configure webdriver with travis in PHP?

Hi, I want to make the tests I do in selenium can be automated in travis, but I have no idea how I have to configure the travis.yml for this, I tried several configurations that I found but none worked. I have been testing the code directly with the default localhost and only with chrome.
Currently my test is as follows


use PHPUnit\Framework\TestCase;
use Facebook\WebDriver;

class ProbandoIngresarDatosTest extends TestCase
     * @var WebDriver\Remote\RemoteWebDriver
    private $webDriver;

     * @var string
    private $baseUrl;

     * init webdriver
    public function setUp():void
        $desiredCapabilities = WebDriver\Remote\DesiredCapabilities::chrome();
        $desiredCapabilities->setCapability('trustAllSSLCertificates', true);
        $this->webDriver = WebDriver\Remote\RemoteWebDriver::create('http://localhost:4444/wd/hub', $desiredCapabilities);

     * Method testProbandoIngresarDatos
     * @test
    public function testProbandoIngresarDatosYMandarEmail()
        $this->webDriver->findElement(WebDriver\WebDriverBy::id("mensaje"))->sendKeys("Estoy probando ingresar datos en el formulario");
		$this->assertStringContainsString('Ezequiel',  $this->webDriver->getTitle());

     * Close the current window.
    public function tearDown():void

     * @param WebDriver\Remote\RemoteWebElement $element
     * @return WebDriver\WebDriverSelect
     * @throws WebDriver\Exception\UnexpectedTagNameException
    private function getSelect(WebDriver\Remote\RemoteWebElement $element): WebDriver\WebDriverSelect
        return new WebDriver\WebDriverSelect($element);

The travis configuration for

language: php

* 7.3
  * DISPLAY=:99.0
  * BROWSER_NAME="turismonacionaleinternacional"
  * SELENIUM_SERVER="" # Latest version including HtmlUnit
* mysql
* xvfb
* "composer install"
script: phpunit --configuration phpunit.xml --coverage-text
  * wget;
  * unzip;
  * "wget"
  * "java -jar selenium-server-standalone-3.14.0.jar "
  * php -S localhost:4444 -t test/funcional/ &>>./logs/php-server.log &
  * until $(echo | nc localhost 4444); do sleep 1; echo waiting for PHP server on port 4444...; done; echo "PHP server started"
  * sleep 30

and now it is stuck in this way and does not take into account the tests

14:15:27.361 INFO [GridLauncherV3$1.launch] - Launching a standalone Selenium Server on port 4444
2020-02-09 14:15:27.702:INFO::main: Logging initialized @811ms to org.seleniumhq.jetty9.util.log.StdErrLog
14:15:27.995 INFO [SeleniumServer.boot] - Selenium Server is up and running on port 4444

No output has been received in the last 10m0s, this potentially indicates a stalled build or something wrong with the build itself.
Check the details on how to adjust your build configuration on:

From what I can see, you need to run the Selenium server in background (and terminate it at the end) so that you can do something else while it’s running.

It’s probably best to find a sample/tutorial by someone who walked this road before. Travis doesn’t endorse or promote any particular ways of doing things beyond what the stock functionality provides.

Existing functionality for GUI and browser testing is described at

Yes, I managed to run in the background by adding &, but now I’m throwing another error that I don’t know why

Make that change and now I’m throwing a different error for missing binaries of google, how could I add that?

Facebook\WebDriver\Exception\SessionNotCreatedException: Unable to create new service: ChromeDriverService
Build info: version: ‘3.14.0’, revision: ‘aacccce0’, time: ‘2018-08-02T20:13:22.693Z’
System info: host: ‘travis-job-8491317f-10fa-4728-9098-8fd05105686a’, ip: ‘’, ‘Linux’, os.arch: ‘amd64’, os.version: ‘4.15.0-1028-gcp’, java.version: ‘11.0.2’
Driver info: driver.version: unknown