Skip to content

Commit 740b964

Browse files
committed
fixup! Elaborate a little more in the warning message for config.cache
1 parent 141f3ec commit 740b964

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

tests/test_builders/test_build_warnings.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,8 +73,8 @@ def test_texinfo_warnings(app, warning):
7373

7474

7575
def test_uncacheable_config_warning(make_app, tmp_path):
76-
"""Test than an unpickleable config value raises a warning."""
77-
tmp_path.joinpath('conf.py').write_text("""
76+
"""Test that an unpickleable config value raises a warning."""
77+
tmp_path.joinpath('conf.py').write_text("""\
7878
my_config = lambda: None
7979
show_warning_types = True
8080
def setup(app):
@@ -84,5 +84,6 @@ def setup(app):
8484
app = make_app(srcdir=tmp_path)
8585
app.build()
8686
assert strip_colors(app.warning.getvalue()).strip() == (
87-
"WARNING: cannot cache unpickable configuration value: 'my_config' [config.cache]"
87+
"WARNING: cannot cache unpickable configuration value: 'my_config' "
88+
"(because it contains a function, class, or module object) [config.cache]"
8889
)

0 commit comments

Comments
 (0)