Repository navigation
Une seule règle de résolution des URL du back-office - #125
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…fficeUrl Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… back-office Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…s, README Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Objectif
Une seule règle complète désormais une URL du back-office relative : celle des suites visuelles, alignée sur l'app. Avant,
loadGlobals()(toutes les suites, en CLI et en CI) collait simplementPRESTAFLOW_BO_URLderrièrePRESTAFLOW_FO_URL.PRESTAFLOW_BO_URL(FOhttps://x/)/adminhttps://x//admin/https://x/admin/admin-dev/avec une FOhttps://x/?lang=2https://x/?lang=2/admin-dev/https://x/admin-dev///autre/adminhttps://x///autre/admin/https://autre/admin/HTTPS://bo/adminhttps://x/HTTPS://bo/admin/HTTPS://bo/admin/adminhttps://x/ admin /https://x/admin/admin123, absente (admin-dev/), videChangements
PrestaFlow\Library\Utils\BackOfficeUrl, à deux méthodes :resolve()reprend le corps de l'ancienVisualTestsSuite::resolveBackOfficeUrl();isRelative()indique si une URL du back-office est à compléter.VisualTestsSuite::resolveBackOfficeUrl()reste publique, avec la même signature, et délègue à l'utilitaire.TestsSuite::loadGlobals()passe par l'utilitaire.$backOfficeRelativesuit un chemin relatif, le défautadmin-dev/ou une valeur vide : la BO continue alors de suivre une$shopUrldu fichier.//hôteest gardée telle quelle.$shopUrl/$backOfficeUrl.PRESTAFLOW_BO_URL, et le cas//hostest précisé.PRESTAFLOW_*_URLsauvegardent et restaurent$_ENVet l'environnement du processus.Tests
694 tests verts en PHP 8.4 et 8.1, et en ordre aléatoire :
BackOfficeUrlTest: cas partagés avec l'app et cas limites ;LoadGlobalsBackOfficeUrlTest: nouveau ;VisualTestsSuiteUrlsTest: BO//hôteet BO vide avec$shopUrl.Aucun test ne lance Chrome.
Spec :
docs/superpowers/specs/2026-10-08-bo-url-resolve-design.md. Plan :docs/superpowers/plans/2026-10-08-bo-url-resolve.md.🤖 Generated with Claude Code