def test_list_transaction(self, _term_width): sack = self.base.sack q = sack.query().filter(name='pepper') i = q.installed()[0] u = q.available()[0] obs = sack.query().filter(name='hole').installed()[0] transaction = dnf.transaction.Transaction() transaction.add_upgrade(u, i, [obs]) self.assertEqual(self.output.list_transaction(transaction), LIST_TRANSACTION_OUTPUT)
def test_list_transaction(self, _term_width): sack = support.MockYumBase('updates').sack q = sack.query().filter(name='pepper') i = q.installed()[0] u = q.available()[0] obs = sack.query().filter(name='hole').installed()[0] transaction = dnf.transaction.Transaction() transaction.add_upgrade(u, i, [obs]) self.output._transaction = transaction self.assertEqual(self.output.list_transaction(), OUTPUT)