Since #2417075: Trusted host verification is incompatible with URIs with the "internal" scheme was committed it is no longer possible to run all the phpunit tests in one go using phpunit. The only reason 8.0.x is green is because simpletest runs each phpunit test in an individual process.

CommentFileSizeAuthor
#2 2448223.2.patch708 bytesalexpott
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mpdonadio’s picture

Assigned: Unassigned » mpdonadio

I think I know what is going on. Will try some things.

alexpott’s picture

Status: Active » Needs review
FileSize
708 bytes

We're setting a request factory which is statically persisted on the request which impacts other unit tests.

alexpott’s picture

The fix applied is exactly the same as in Symfony\Component\HttpFoundation\Tests\RequestTest::testFactory()

mpdonadio’s picture

Assigned: mpdonadio » Unassigned
Status: Needs review » Reviewed & tested by the community

Assuming this comes back green from TestBot, it is RTBC. I was able to reproduce the problem before the patch, and the tests all pass when I run phpunit from the CLI.

tstoeckler’s picture

Sorry about that. Fix seems legit, thanks.

webchick’s picture

Status: Reviewed & tested by the community » Fixed

Suppose there's no way to add tests for running tests? :)

Committed and pushed to 8.0.x. Thanks!

  • webchick committed 876e15c on 8.0.x
    Issue #2448223 by alexpott: Cannot run all PHPUnit tests using PHPUnit
    
neclimdul’s picture

there was an issue to use the phpunit test runner on testbot but I haven't seen it pop up in a while.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.