diff --git a/tests/test_builders/test_build_html_copyright.py b/tests/test_builders/test_build_html_copyright.py index 7a18bceb603..86a5cdf1663 100644 --- a/tests/test_builders/test_build_html_copyright.py +++ b/tests/test_builders/test_build_html_copyright.py @@ -9,6 +9,13 @@ LOCALTIME_2009 = type(LT)(LT_NEW) +@pytest.fixture +def source_date_empty(monkeypatch): + with monkeypatch.context() as m: + m.delenv('SOURCE_DATE_EPOCH', raising=False) + yield + + @pytest.fixture( params=[ 1199145600, # 2008-01-01 00:00:00 @@ -24,7 +31,7 @@ def source_date_year(request, monkeypatch): @pytest.mark.sphinx('html', testroot='copyright-multiline') -def test_html_multi_line_copyright(app): +def test_html_multi_line_copyright(source_date_empty, app): app.build(force_all=True) content = (app.outdir / 'index.html').read_text(encoding='utf-8')