diff --git a/tests/Feature/CmsSectionLegacyRenderTest.php b/tests/Feature/CmsSectionLegacyRenderTest.php index 297292b..85c5cc9 100644 --- a/tests/Feature/CmsSectionLegacyRenderTest.php +++ b/tests/Feature/CmsSectionLegacyRenderTest.php @@ -90,6 +90,8 @@ private function sectionsMarkup(string $html): string $end = strpos($html, ''); $markup = substr($html, $start, $end - $start); $markup = (string) preg_replace('/\b(id|aria-labelledby|aria-describedby|for)="([^"]*[0-9a-f]{8}-[0-9a-f]{4}-[^"]*)"/', '$1="#"', $markup); + // Die Basisadresse hängt von der Umgebung ab (APP_URL), die Pfade der Bilder nicht. + $markup = (string) preg_replace('#https?://[^/"\s]+/medien/#', 'HOST/medien/', $markup); $markup = (string) preg_replace('/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}/', 'UUID', $markup); return trim($markup)."\n"; diff --git a/tests/Fixtures/section-legacy-render.html b/tests/Fixtures/section-legacy-render.html index 58c7a11..a3fdd84 100644 --- a/tests/Fixtures/section-legacy-render.html +++ b/tests/Fixtures/section-legacy-render.html @@ -1 +1 @@ -

default narrow

Text default narrow

default standard

Text default standard

default wide

Text default wide

default full

Text default full

light wide

Text light wide

dark narrow

Text dark narrow

dark standard

Text dark standard

dark wide

Text dark wide

dark full

Text dark full

accent wide

Text accent wide

Bild light center

Bild light top_left

Bild dark center

Bild dark top_left

Bild none center

Bild none top_left

Abstand none

Rechts

Abstand compact

Rechts

Abstand normal

Rechts

Abstand large

Rechts

Trenner Akzent

Eins

Drei

+

default narrow

Text default narrow

default standard

Text default standard

default wide

Text default wide

default full

Text default full

light wide

Text light wide

dark narrow

Text dark narrow

dark standard

Text dark standard

dark wide

Text dark wide

dark full

Text dark full

accent wide

Text accent wide

Bild light center

Bild light top_left

Bild dark center

Bild dark top_left

Bild none center

Bild none top_left

Abstand none

Rechts

Abstand compact

Rechts

Abstand normal

Rechts

Abstand large

Rechts

Trenner Akzent

Eins

Drei