Ultimate-Multisite / Ultimate-Multisite/ultimate-multisite

Clean PHPUnit bootstrap and PHP 8.4 deprecations

Open
#1,810 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

auto-dispatch blocked-by:GH#1805 origin:interactive priority:high quality-debt status:blocked tier:standard
Dominant language
PHP
Stars
214
Forks
86
Avg merge
5h 29m
Merged PRs (30d)
60

Description

What

Make the PHPUnit bootstrap clean on PHP 8.4 by removing duplicate custom-table installation notices and addressing actionable dependency deprecations observed during #1805.

Why

Tests pass, but noisy bootstrap output can hide real database failures and future PHP compatibility regressions. Interrupted runs can also leave the disposable test schema incomplete.

Tier

tier:standard — the investigation spans the WordPress test bootstrap, Ultimate Multisite installers, BerlinDB table creation, and pinned validation dependencies.

Files

  • tests/bootstrap.php
  • inc/class-requirements.php or the verified requirements implementation
  • inc/installers/ database setup paths
  • composer.json and composer.lock if dependency updates are required
  • Focused installer/bootstrap tests

Reference pattern

Reproduce with an empty disposable wptests_ schema and XDEBUG_MODE=off vendor/bin/phpunit --filter WP_Ultimo_Main_Test. Verify installed dependency versions and local exports before changing third-party compatibility code.

Implementation steps

  1. Trace why custom wptests_wu_* tables are created more than once during bootstrap.
  2. Make installation idempotent without suppressing genuine database errors.
  3. Separate WordPress-core deprecations from plugin/dependency deprecations.
  4. Update or patch pinned dependencies only when verified against local package source.
  5. Add a regression test for clean repeated bootstrap or installer execution.

Acceptance criteria

  • Focused tests produce no duplicate-table database notices.
  • Plugin-owned PHP 8.4 deprecations are removed.
  • External WordPress-core-only notices are documented separately if unavoidable.
  • Repeated installer execution remains idempotent.
  • Focused and full PHPUnit runs pass.

Verification

  • XDEBUG_MODE=off vendor/bin/phpunit --filter WP_Ultimo_Main_Test
  • XDEBUG_MODE=off vendor/bin/phpunit
  • pnpm run quality

Dependency

Blocked by #1805; begin after PR #1806 merges.


aidevops.sh v3.32.317 plugin for OpenCode v1.18.29 with gpt-5.6-sol spent 4h 26m and 539,830 tokens on this with the user in an interactive session.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue with an empty disposable wptests_ schema using the focused PHPUnit command, then trace tests/bootstrap.php and the inc/installers/ database setup paths for repeated custom-table creation. Check inc/class-requirements.php, composer.json, and composer.lock before assessing dependency deprecations. Done means focused and full PHPUnit runs are clean, repeated installation is idempotent, and unavoidable WordPress-core notices are documented separately.

Written by the indexing model from the issue text.

Assessment

Tech stack
php, wordpress
Domain
backend, database, testing
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.