release: 1.5.0 (framework ^1.7)#25
Merged
Merged
Conversation
…dependent AuthMiddlewareTest depended on the calling shell's OPENSSL_CONF for openssl_pkey_new/export, which fails on hosts with a broken or missing config and has no portable fallback. Generate a minimal self-contained config per test run instead. WpMaintenanceGateTest wrote to a shared fixed path (/tmp/wordpress/), which breaks with permission denied when that path is owned by a different uid on the host. Use a per-process temp dir keyed by pid.
Lines 91.40%->94.29%, methods 75.21%->82.34%, classes 50.65%->61.04%.
Real behavior gaps closed: WpdbConnectionAdapter (query/update wpdb
failure -> exception, named-param-with-no-token passthrough),
PostMetaRepository/UserMeta-adjacent Router (unmatched-pattern ->
null), AuthMiddleware (setIssuer, session-absent null path, bare
env-var fallback, missing-sub-claim rejection, refresh-token branches,
generateRefreshToken's own missing-key guard via reflection),
FieldRenderer (Textarea control), FieldType (CheckboxList sanitizer's
array branch), SettingsRegistrar::all(), SettingsPageRegistrar (the
recorded field/section callbacks actually invoked, mirroring how
WordPress calls them at render time), HookRegistrar (non-.php skip,
fixture file), WpUploadsFilesystem (mkdir failure, warning silenced
the same way RotatingStreamHandler's `silenced()` does), HttpClient
(non-CurlHandle handed to the http_api_curl action), and InertiaAdapter
(isPartialReload()/getPartialData(), driven directly via reflection
since their only caller, sendJson(), exits).
Left deliberately alone (each already documented as an accepted gap in
the class's own docblock/test, not a silent oversight):
- InertiaAdapter::sendJson()/location() and CsrfGuard::reject(): exit
the process, "intentionally left to the untested exit path" per
InertiaAdapterCoverageTest's docblock.
- WpMaintenanceGate's wp_is_maintenance_mode()/ABSPATH branches:
WpMaintenanceGateTest documents `wp_is_maintenance_mode()` as
deliberately unstubbed.
- The ~25 Support/* `function_exists('wp_*')` guards, plus similar
guards in HttpClient/WpHookfileLoader: every one of those WP
functions IS stubbed in tests/stubs/wp-stubs.php (loaded once for the
whole run), so the "function absent" branch is unreachable within a
single PHPUnit process without shadowing an already-defined global
function — not a pattern used anywhere in this suite.
- PostMetaRepository/UserMeta's non-array-meta guards: get_post_meta()/
get_user_meta() always return an array from the stub.
- AuthMiddleware::isAuthenticated()'s unauthenticated-but-no-error
branch: only reachable if get_user_by() disagrees with itself between
two calls in the same request — a should-never-happen race, not a
normal code path.
Remove PhpErrorLogLogger (the zero-dep PSR-3 error_log fallback) and its test; the canonical implementation now lives in middag-io/framework as ErrorLogFallbackLogger. Repoint the LogSupport @see reference to it and drop the now-stale src/Logging/ row from the structure table. BREAKING CHANGE: Middag\WordPress\Logging\PhpErrorLogLogger is removed. Use Middag\Framework\Logging\ErrorLogFallbackLogger instead (identical behaviour and constructor signature).
Release-As: 1.5.0
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bump middag-io/framework floor to ^1.7 and cut minor release 1.5.0.
Includes since 1.4.0:
Release-As: 1.5.0forces the minor bump (overrides the breaking-change major default).