~sbeattie/conflictchecker/conflictchecker-fixups

« back to all changes in this revision

Viewing changes to findconflicts/tests/test_persistence.py

  • Committer: Michael Vogt
  • Date: 2007-07-16 10:26:52 UTC
  • Revision ID: michael.vogt@ubuntu.com-20070716102652-i52d196wc72h1lwh
* store the preinst hash into the database when scanning new packages

Show diffs side-by-side

added added

removed removed

Lines of Context:
755
755
            'diversions':[],
756
756
            }
757
757
        package = PackageVersion.InsertFromInfo(info, store)
 
758
        # if preinst_hash is in info dict, it should be added to the package
 
759
        info = {
 
760
            'controltext':'controltext',
 
761
            'files':[],
 
762
            'name':'foo',
 
763
            'version':'0.1-0ubuntu5',
 
764
            'arch':'sparc',
 
765
            'preinst_hash':'foobarbaz'
 
766
            }
 
767
        package = PackageVersion.InsertFromInfo(info, store)
 
768
        self.assertEqual('foobarbaz', package.preinst_hash)
758
769
 
759
770
    def test_find_unsafely_colocated_packages_sole_package(self):
760
771
        """When there is one package in the store, no colocation happens."""