From cc8030b0742f382cc6751750fae5be80e7e492c4 Mon Sep 17 00:00:00 2001 From: Georg Brandl Date: Sun, 15 Mar 2009 19:04:02 +0100 Subject: [PATCH] Fix test_env after update() API change. --- tests/test_env.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tests/test_env.py b/tests/test_env.py index 0b944c509..a06656d69 100644 --- a/tests/test_env.py +++ b/tests/test_env.py @@ -37,8 +37,7 @@ def warning_emitted(file, text): # afford to not run update() in the setup but in its own test def test_first_update(): - it = env.update(app.config, app.srcdir, app.doctreedir, app) - msg = it.next() + msg, num, it = env.update(app.config, app.srcdir, app.doctreedir, app) assert msg.endswith('%d added, 0 changed, 0 removed' % len(env.found_docs)) docnames = set() for docname in it: # the generator does all the work @@ -80,8 +79,7 @@ def test_second_update(): # the contents.txt toctree; otherwise section numbers would shift (root / 'autodoc.txt').unlink() (root / 'new.txt').write_text('New file\n========\n') - it = env.update(app.config, app.srcdir, app.doctreedir, app) - msg = it.next() + msg, num, it = env.update(app.config, app.srcdir, app.doctreedir, app) assert '1 added, 3 changed, 1 removed' in msg docnames = set() for docname in it: