Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#46414 closed defect (bug) (fixed)

Multisite PHPUnit configuration file throws validation error

Reported by: desrosj's profile desrosj Owned by: desrosj's profile desrosj
Milestone: 5.2 Priority: normal
Severity: minor Version: 4.1
Component: Build/Test Tools Keywords: has-patch commit
Focuses: multisite Cc:


When running PHPUnit 7.x (jobs with PHP 7.1+ in Core's Travis configuration), the following warning is output:

 Warning - The configuration file did not pass validation!
  The following problems have been detected:
  Line 44:
  - Element 'php': This element is not expected.
  Test results may not be as expected.

I believe this is being caused by the presence of two <php> tags in tests/phpunit/multisite.xml, though I have not been able to find this explicitly stated in PHPUnit's documentation. Consolidating those into one fixes the validation error.

Attachments (1)

46414.diff (660 bytes) - added by desrosj 5 years ago.

Download all attachments as: .zip

Change History (3)

5 years ago

#1 @jeremyfelt
5 years ago

  • Focuses multisite added
  • Keywords commit added
  • Version set to 4.1

Looks like this was just incidental when applying [29869] to multisite in [29954].

#2 @desrosj
5 years ago

  • Owner set to desrosj
  • Resolution set to fixed
  • Status changed from new to closed

In 44790:

Build/Test Tools: Fix validation error in multisite PHPUnit configuration file.

A PHPUnit configuration file with more than one <php> tag causes a validation error in PHPUnit versions 7.x. There are currently 2 in the tests/phpunit/multisite.xml file, which appears to be accidentally introduced in [29954].

Fixes #46414.

Note: See TracTickets for help on using tickets.