Skip to content

Running tests as a multisite fails to submit testing report #267

Open

Description

@desrosj

Describe the bug
When the test runner is configured to run the unit test suite as a multisite, the results will not be submitted successfully because no junit.xml file is produced.

I've opened a ticket upstream in Core Trac, but I'm creating this to follow up once that's addressed, and to consider any other functional differences when running the tests as a multisite install.

To Reproduce
Steps to reproduce the behavior:

  1. Prepare and run the test runner with WPT_FLAVOR=1.
  2. Run the reporting script.
  3. Observe a failure.
  4. Inspect the tests/phpunit/build/logs directory and see that there is no junit.xml file.

Activity

  1. self-assigned this
    on Sep 18, 2025
  2. desrosj commented on Sep 18, 2025

    @desrosj
    MemberAuthor

    This was merged in r60781, but needs some testing to confirm.

  3. added and removed
    WCUS-CD-2025Tickets and issues worked on during WCUS Contributor Day 2025
    on Aug 12, 2026
  4. moved this from In progress to In review in Hosting Team WCUS 2026on Aug 12, 2026
  5. moved this from In review to Ready in Hosting Team WCUS 2026on Aug 16, 2026
  6. chrisdavidmiles commented on Oct 14, 2026

    @chrisdavidmiles

    Confirmed fixed on trunk, but it took a follow-up, not just r60781.

    test.php runs multisite as phpunit -c tests/phpunit/multisite.xml, and report.php reads tests/phpunit/build/logs/junit.xml. PHPUnit resolves a <log> target relative to the config file's own directory (tests/phpunit/).

    • r60781 added the log with target="tests/phpunit/build/logs/junit.xml", which resolves to tests/phpunit/tests/phpunit/build/logs/junit.xml (a doubled path). report.php never finds it there, so multisite reporting still fails.
    • r62464 (#64894, "Correct the Multisite PHPUnit log path") changed it to target="build/logs/junit.xml", which resolves to tests/phpunit/build/logs/junit.xml, where report.php looks.

    Reproduced both with PHPUnit 9.6 and a one-test suite, config in tests/phpunit/ run from the repo root as the runner does. The r60781 path writes to the doubled location (report aborts). The r62464 path writes where report.php reads (report succeeds). So this is resolved on current trunk. Just confirm any test build is at or after r62464, since r60781 by itself does not do it.

    AI Assisted Claude Code helped test the multisite log path, confirming r60781 alone missed the path and r62464 corrected it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions