Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] CI for FunctionalJavascript tests not working #889

Open
rosiel opened this issue Jul 22, 2022 · 1 comment
Open

[BUG] CI for FunctionalJavascript tests not working #889

rosiel opened this issue Jul 22, 2022 · 1 comment

Comments

@rosiel
Copy link
Member

rosiel commented Jul 22, 2022

On every Islandora CI run, the FunctionalJavascript tests show up as green, but the tests were skipped (so they didn't actually run!)

The problem is with setting up and connecting Chromedriver. I've made some attempts but no success.

Skipped test message:

There was 1 skipped test:

1) Drupal\Tests\islandora\FunctionalJavascript\IntegerWeightTest::testIntegerWeightSelector
The test wasn't able to connect to your webdriver instance. For more information read core/tests/README.md.

The original message while starting Mink: Could not open connection: unknown error: Chrome failed to start: exited abnormally.
  (unknown error: DevToolsActivePort file doesn't exist)
  (The process started from chrome location /usr/bin/google-chrome is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
  (Driver info: chromedriver=103.0.5060.134 (8ec6fce403b3feb0869b0732eda8bd95011d333c-refs/branch-heads/5060@{#1262}),platform=Linux 5.15.0-1014-azure x86_64)

/opt/drupal/web/core/tests/Drupal/FunctionalJavascriptTests/WebDriverTestBase.php:55
/opt/drupal/web/core/tests/Drupal/Tests/BrowserTestBase.php:381
/home/runner/work/islandora/islandora/build_dir/tests/src/FunctionalJavascript/IntegerWeightTest.php:84
/opt/drupal/vendor/phpunit/phpunit/src/Framework/TestResult.php:726

The attempt to fix (resulted in above error):

build-2.x.yml

        # needed for FunctionalJavascript
      - name: Setup chromedriver
        uses: nanasess/setup-chromedriver@v1

      - name: Start chromedriver
        run: |
          export DISPLAY=:99
          chromedriver --port=4444 --no-sandbox --url-base=/wd/hub &

phpunit.xml

    <env name="MINK_DRIVER_ARGS_WEBDRIVER" value='["chrome", { "chromeOptions": { "w3c": false } }, "http://localhost:4444/wd/hub"]'/>
@rosiel
Copy link
Member Author

rosiel commented Jun 22, 2023

Bumping this up as it was mentioned recently - if you can get a web browser working in CI that Islandora can talk to, that would be great! (As far as I know, Islandora is the only module in our suite of modules/repositories that uses functional javascript tests. )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant