I configured PHPStorm so that it can run PHPUnit tests for Drupal sites.
In PHPStorm I clicked a button to run a test, then I got the message that the test failed.
Of course, in a PHPStorm window I could see the detailed command line for running PHPUnit like following:
/usr/bin/php7.3 xxx/vendor/phpunit/phpunit/phpunit --bootstrap xxx/core/tests/bootstrap.php --configuration xxx/modules/phpunit.xml --teamcity
Then I copied the command line to a terminal in the OS (Ubuntu), and ran it, and guess what, it passed! So I am very confused with the fact, that the same command line will lead to different results in PHPStorm and in a terminal in Ubuntu.
As I know, for running certain Drupal tests it restricts the user who runs the tests (see following post):
When running the tests in a Ubuntu Terminal, the user is *dev*, with this user the tests are OK.
So I'm wondering if PHPStorm takes an other username when running PHPUnit Tests? If so, what is that?
Thank you very much for your support.