From 19e2e0f210da3fb4cb87cfe1ddd4bbc6c61d8cd1 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Thu, 26 May 2011 18:01:26 +0200 Subject: merge from debian, omit disable of the 0.7 API --- tests/test_progress.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tests/test_progress.py') diff --git a/tests/test_progress.py b/tests/test_progress.py index ffab5bc0..73853dfa 100644 --- a/tests/test_progress.py +++ b/tests/test_progress.py @@ -34,7 +34,8 @@ class TestProgress(unittest.TestCase): apt_pkg.config.set("Dir::state::lists", "./tmp") # create artifical line deb_line = "deb file:%s/data/fake-packages/ /\n" % basedir - open("fetch_sources.list","w").write(deb_line) + with open("fetch_sources.list","w") as fobj: + fobj.write(deb_line) apt_pkg.config.set("Dir::Etc::sourcelist", "fetch_sources.list") def test_acquire_progress(self): -- cgit v1.2.3