def test_other_essential(self):
     checker = DummyChecker({'simple': Version('1.1')}, {'simple'})
     orig = PkgRelation.parse('simple (>= 1.0) | other')
     self.assertEqual(([], PkgRelation.parse('simple (>= 1.0) | other')),
                      drop_obsolete_depends(orig, checker))
 def test_single(self):
     checker = DummyChecker({'simple': Version('1.1')}, {})
     orig = PkgRelation.parse('simple (>= 1.0)')
     self.assertEqual((PkgRelation.parse('simple'),
                       PkgRelation.parse('simple (>= 1.0)')),
                      drop_obsolete_depends(orig, checker))
 def test_debhelper(self):
     checker = DummyChecker({'debhelper': Version('1.4')}, {})
     orig = PkgRelation.parse('debhelper (>= 1.1)')
     self.assertEqual((PkgRelation.parse('debhelper (>= 1.1)'), []),
                      drop_obsolete_depends(orig, checker))
 def test_empty(self):
     self.assertEqual(([], []),
                      drop_obsolete_depends([], DummyChecker({}, [])))