@mxr576 thanks for the patch.
I tried it after I met some issues on a project where Drupal is a package in a pnpm monorepo. Kernel tests were failing because of hardlinks:
RuntimeException: SplFileInfo::openFile(/Users/alex/work/silverback-mono/apps/silverback-drupal/web/modules/contrib/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/tests/Cypress/node_modules/@-drupal/test_session/test_session.info.yml): Failed to open stream: Invalid argument
Looks beautiful, right? :D
So I tried the patch and found the following:
1. There is a typo:
setting.testing.php
instead ofsettings.testing.php
2.
file_scan_ignore_directories
should be set beforeDatabase::addConnectionInfo('default', 'test-runner', $this->getDatabaseConnectionInfo()['default']);
. Otherwise, the error persists.3. I solved the two above issues, but found that tests run crazy slow. Even if they pass. So it looks like something else still scans the blackhole :)
In the end I found another Drupal-unrelated solution. But maybe my findings will help someone.
- 🇭🇺Hungary mxr576 Hungary
@Leksat, Hi, thanks for the details. I have fixed what I could easily :) 2nd point needs further investigation.
How do we do monorepo with Drupal has also changed recently, so I am not sure if we are still using this patch. I need to check.