Skip to content

Test Plan Cross Platform Divergence Modernized

github-actions[bot] edited this page Nov 29, 2026 · 2 revisions

Test Plan Cross-Platform Result Divergence (platformDivergence) — Modernized (2.0.1)

Issue: #2097. Screen: gui/templates/results/platformDivergence.html. BFF: api/platformdivergence/index.php.

This net-new read-only test-plan report answers one question the 1.9.20 screens did not: where do different platforms of the same plan disagree about the latest result of the same test-case version? It joins plan assignments, active platforms, builds and the latest execution per platform into a single Dashio report with divergence classes, KPIs, filters, evidence detail and guarded CSV export.

Why a new screen

Legacy reports showed result matrices and platform comparisons as separate views; they did not promote conflicting verdicts for one version to a triage list. platformDivergence groups assigned versions with evidence on at least two platforms and classifies them as mixed_pass_fail, mixed_pass_blocked, mixed_fail_blocked, mixed_unknown or consistent.

Screen

  • Toolbar: Build, Platform, Divergence, Contains result and Search filters, Refresh, Export CSV, Apply and Close.
  • Context panel: plan, project, applied build and platform.
  • Verdict banner: no_data, critical (pass/fail conflicts), watch (blocked conflicts) and healthy.
  • KPI strip: versions with evidence, divergent/consistent versions, each mixed class, platform evidences, passed/failed/blocked counts and divergence percentage.
  • DataTable: 10 columns — prefixed external ID, test case, suite path, version, platform count, divergence class, passed/failed/blocked counts, per-platform latest evidence and a Details button.
  • Detail modal: row summary, latest result on each platform with build/time/notes, and execution history capped at 20 newest rows per platform and 100 overall with a localized truncation note.
  • UTF-8 CSV with BOM, ; delimiter, quoted cells, formula-injection guard and localized toast; localized 400/401/403/404/405 state cards and a TLi18n locale switcher.

Semantics

  • Scope is testplan_tcversions assigned to the selected plan; only versions with latest evidence on at least two distinct platforms appear in the table and KPIs.
  • Active plan platforms are the union of testplan_platforms.active = 1, platforms used by assigned tcversions and platforms used by plan executions, intersected with the owning project's platforms. This avoids dropping evidence when testplan_platforms is incomplete (bug #2098).
  • build_id = 0 and platform_id = 0 mean no filter; platform_id = 0 assignments apply to every platform of the plan.
  • The latest evidence is the execution with the highest id for each (version, platform) pair inside the applied build scope; unknown statuses count as mixed_unknown.
  • Rights (testplan_metrics) are checked on the OWNING project of the plan before the client-supplied tproject_id assertion; denials return no_right and write an AUDIT event.

API contract

Case HTTP Code
GET|HEAD action=init|report|detail success 200 ok
Unknown action / missing tplan_id / invalid filter value 400 invalid_request
Anonymous / expired session 401 not_authenticated / session_expired
Missing testplan_metrics on the owning project 403 no_right (AUDIT)
Unknown plan / wrong project / unknown version in detail 404 tplan_not_found / project_mismatch / version_not_found
Non GET/HEAD 405 method_not_allowed (Allow: GET, HEAD)

Security: bffSameOriginGuard() + bffEnforceSession() (the origin guard is a no-op for read-only GET/HEAD), nosniff and no-store headers, integer-only IDs, html_entity_decode on display data, escaped client rendering and AUDIT logging for denials.

Wiring

  • cfg/reports.cfg.php — platform_divergence report entry.
  • api/aside/index.php — modern report mapping with project/plan context.
  • lib/functions/common.php — $actions->platformDivergence.
  • gui/templates/i18n/*.json — 90 pdv.* + footer keys in all 10 bundles; ai/verify_i18n_coverage.sh passes 9/9 with 14044 keys.
  • locale/*/strings.txt — $TLS_link_report_platform_divergence in all 19 server locales.

Verification

  • Fixture tmp/fixtures_2097.php: project PDV2097, plan PDV Plan, 3 platforms, 2 builds, 7 assigned versions and 13 controlled executions (12 included platform evidences); a role-3 viewer is added for the denial path.
  • Suite Issue #2097: BFF contract, metrics, divergence classes, filters, browser states, modal, CSV, RO locale, permissions, errors, i18n and Event Viewer all PASS; suite gate reports 34 PASS / 0 FAIL / 0 SKIP.
  • Bug #2098 (platforms absent from testplan_platforms were omitted) was filed with the bug label, fixed by unioning plan-platform sources, browser-reverified and closed.
  • PHP lint, JSON validation, i18n coverage and suite gates pass. Event Viewer has 0 new Error/Warning rows after all fixes.

Screenshots

Normal report with KPIs and verdict banner Pass/fail divergence filter applied Platform divergence evidence detail modal Romanian locale No-right 403 card

Clone this wiki locally