mirror of
https://github.com/jorijn/meshcore-stats.git
synced 2026-07-07 02:01:26 +02:00
fix(html): use relative asset and nav paths for subpath deploys (#84)
This commit is contained in:
committed by
GitHub
parent
3c765a35f2
commit
f21a3788bd
@@ -266,7 +266,8 @@ class TestHtmlOutput:
|
||||
|
||||
content = (out_dir / "day.html").read_text()
|
||||
|
||||
assert "styles.css" in content
|
||||
assert 'href="styles.css"' in content
|
||||
assert 'href="/styles.css"' not in content
|
||||
|
||||
def test_companion_pages_relative_css(self, html_env, metrics_rows):
|
||||
"""Companion pages use relative path to CSS."""
|
||||
@@ -277,4 +278,5 @@ class TestHtmlOutput:
|
||||
content = (out_dir / "companion" / "day.html").read_text()
|
||||
|
||||
# Should reference parent directory CSS
|
||||
assert "../styles.css" in content or "styles.css" in content
|
||||
assert 'href="../styles.css"' in content
|
||||
assert 'href="/styles.css"' not in content
|
||||
|
||||
Reference in New Issue
Block a user