Skip to content

Commit 98759ca

Browse files
committed
Fixed the problem with empty entries for apt_packages, adjusted tests
1 parent 15078cd commit 98759ca

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

template/.readthedocs.yml.jinja

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,9 @@ build:
1313
{%- if apt_packages != "" %}
1414
apt_packages:
1515
{%- for package in apt_packages.split(',') %}
16+
{%- if package.strip() != "" %}
1617
- {{ package.strip() }}
18+
{%- endif %}
1719
{%- endfor %}
1820
{%- endif %}
1921

tests/test_copier.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ def test_content_docs_multiple_files(default_project, file_name):
177177

178178
@pytest.mark.parametrize("desired", [
179179
' apt_packages:\n'
180-
' - libsndfile1',
180+
' - libsndfile1\n\n',
181181
' python: "3.14"',
182182
" include:\n - path/to/submodule",
183183
])

0 commit comments

Comments
 (0)