coding style issues fixed

This commit is contained in:
Nicolas 2025-05-30 17:08:38 +02:00
parent a65bb1c8e5
commit ecc97bd9a6
2 changed files with 5 additions and 7 deletions

View File

@ -90,8 +90,6 @@ def test_html_render():
document_validation.validate_html(html_code, VALIDATE_HTML_CODE_ONLINE)
title = 'Test HTML Render 2'
if WRITE_RESULT_FILES:
with open('tests/out/test_html_render2.html', 'w', encoding='utf-8') as f:
f.write(pyladoc.inject_to_template({'CONTENT': html_code}, internal_template='templates/test_template.html'))

View File

@ -1,5 +1,6 @@
import pyladoc
def test_inject_to_template():
template = """
<!DOCTYPE html>
@ -15,14 +16,13 @@ def test_inject_to_template():
</body>
</html>
"""
content = "Hello, World!"
title = "Test Title"
result = pyladoc.inject_to_template({'CONTENT': content, 'TITLE': title},template_string=template)
result = pyladoc.inject_to_template({'CONTENT': content, 'TITLE': title}, template_string=template)
print(result)
assert "Hello, World!" in result
assert "<title>Test Title</title>" in result
assert "<title>Test Title</title>" in result