mirror of
https://github.com/librespeed/speedtest.git
synced 2026-08-04 14:48:38 +00:00
docker: apply TITLE to modern page heading (#788)
Co-authored-by: Stefan Stidl <sti-github@stidl.com>
This commit is contained in:
parent
d18552fe8a
commit
18b46600d0
2 changed files with 2 additions and 1 deletions
|
|
@ -106,7 +106,7 @@ if [[ "$MODE" == "frontend" || "$MODE" == "dual" || "$MODE" == "standalone" ]];
|
|||
TITLE_ESCAPED=$(sed_escape "$TITLE_HTML_ESCAPED")
|
||||
sed -i "s/<title>LibreSpeed<\\/title>/<title>$TITLE_ESCAPED<\\/title>/g; s/<h1>LibreSpeed<\\/h1>/<h1>$TITLE_ESCAPED<\\/h1>/g" /var/www/html/index-classic.html
|
||||
sed -i "s/<title>LibreSpeed<\\/title>/<title>$TITLE_ESCAPED<\\/title>/g" /var/www/html/index.html
|
||||
sed -i "s/<title>LibreSpeed - Free and Open Source Speedtest<\\/title>/<title>$TITLE_ESCAPED - Free and Open Source Speedtest<\\/title>/g" /var/www/html/index-modern.html
|
||||
sed -i "s/<title>LibreSpeed - Free and Open Source Speedtest<\\/title>/<title>$TITLE_ESCAPED - Free and Open Source Speedtest<\\/title>/g; s/<h1>Free and Open Source Speedtest\\.<\\/h1>/<h1>$TITLE_ESCAPED<\\/h1>/g" /var/www/html/index-modern.html
|
||||
fi
|
||||
|
||||
# Support legacy EMAIL env var as fallback for GDPR_EMAIL
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ test.describe('TITLE special characters', () => {
|
|||
test('modern page title supports umlauts and quotes', async ({ page }) => {
|
||||
await page.goto(`${baseUrls.standaloneNew}/index-modern.html`);
|
||||
await expect(page).toHaveTitle(`${specialTitle} - Free and Open Source Speedtest`);
|
||||
await expect(page.locator('main > h1')).toHaveText(specialTitle);
|
||||
});
|
||||
|
||||
test('classic heading supports umlauts and quotes', async ({ page }) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue