~ubuntu-branches/ubuntu/wily/python-cdd/wily-proposed

« back to all changes in this revision

Viewing changes to tests/TestPackage.py

  • Committer: Bazaar Package Importer
  • Author(s): Otavio Salvador, Martin Fuzzey, Otavio Salvador
  • Date: 2010-03-22 11:05:43 UTC
  • Revision ID: james.westby@ubuntu.com-20100322110543-8kc5yynp0l3mba73
Tags: 0.0.10
[ Martin Fuzzey ]
* python-apt 0.8 API transition (Closes: #572055)

[ Otavio Salvador ]
* Update to dpkg-source 3.0 (native) format.

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
class PackageTests(TestBase):
30
30
        def __read_file(self, class_ref, filename):
31
31
                parse_in = open(filename, 'r')
32
 
                parse = apt_pkg.ParseTagFile(parse_in)
 
32
                tagfile = apt_pkg.TagFile(parse_in)
33
33
 
34
34
                pkg_list = []
35
 
                while parse.Step() == 1:
36
 
                        pkg = class_ref(parse.Section)
 
35
                for section in tagfile:
 
36
                        pkg = class_ref(section)
37
37
                        pkg_list.append(pkg)
38
38
                parse_in.close()
39
39