def test_07_assert_unit_uninstall(self):
     unit = {"name": "pike"}
     rpm = RpmUnit(unit, relevant_data_keys=unit.keys())
     assert rpm in RpmUnit.list(self.consumer.cli), "rpm %s not installed on %s" % (rpm, self.consumer)
     with self.pulp.asserting(True):
         response = self.consumer.uninstall_unit(self.pulp, unit, "rpm")
     Task.wait_for_report(self.pulp, response)
     assert rpm not in RpmUnit.list(self.consumer.cli), "rpm %s still installed on %s" % (rpm, self.consumer)
Example #2
0
 def test_07_assert_unit_install(self):
     unit = {'name': 'pike'}
     rpm = RpmUnit(unit, relevant_data_keys=unit.keys())
     with self.pulp.asserting(True):
         response = self.consumer.install_unit(self.pulp, unit, 'rpm')
     Task.wait_for_report(self.pulp, response)
     assert rpm in RpmUnit.list(
         self.consumer.cli), "rpm %s not installed on %s" % (rpm,
                                                             self.consumer)
Example #3
0
    def test_04_assert_unit_install(self):
        unit = {'name': 'pike'}
        rpm = RpmUnit(unit, relevant_data_keys=unit.keys())
        with self.pulp.asserting(True):
            task_reports = [
                consumer.install_unit(self.pulp, unit, 'rpm')
                for consumer in self.consumers
            ]
        Task.wait_for_reports(self.pulp, task_reports)

        for consumer in self.consumers:
            assert rpm in RpmUnit.list(
                consumer.cli), "rpm %s not installed on %s" % (rpm, consumer)
    def test_05_assert_unit_uninstall(self):
        unit = {
            'name': 'zebra'
        }
        rpm = RpmUnit(unit, relevant_data_keys=unit.keys())

        for consumer in self.consumers:
            assert rpm in RpmUnit.list(consumer.cli), "rpm %s not installed on %s" % (rpm, consumer)

        with self.pulp.asserting(True):
            task_reports = [consumer.uninstall_unit(self.pulp, unit, 'rpm') for consumer in self.consumers]
        Task.wait_for_reports(self.pulp, task_reports)

        for consumer in self.consumers:
            assert rpm not in RpmUnit.list(consumer.cli), "rpm %s still installed on %s" % (rpm, consumer)
Example #5
0
 def test_07_assert_nonexisten_unit_uninstall(self):
     unit = {'name': '__NO_SUCH_UNIT__'}
     rpm = RpmUnit(unit, relevant_data_keys=unit.keys())
     with self.pulp.asserting(True):
         task_reports = [
             consumer.uninstall_unit(self.pulp, unit, 'rpm')
             for consumer in self.consumers
         ]
     Task.wait_for_reports(self.pulp, task_reports)
 def test_06_assert_unit_install(self):
     unit = {
         'name': 'pike'
     }
     rpm = RpmUnit(unit, relevant_data_keys=unit.keys())
     with self.pulp.asserting(True):
         response = self.consumer.install_unit(self.pulp, unit, 'rpm')
     Task.wait_for_report(self.pulp, response)
     assert rpm in RpmUnit.list(self.consumer.cli), "rpm %s not installed on %s" % (rpm, self.consumer)
 def test_05_assert_unit_uninstall(self):
     unit = {
         'name': 'zebra'
     }
     self.assertIn(
         RpmUnit(unit, relevant_data_keys=unit.keys()),
         RpmUnit.list(self.consumer_cli)
     )
     Task.wait_for_response(
         self.pulp,
         self.consumer.uninstall_unit(
             self.pulp,
             unit,
             'rpm'
         )
     )
     self.assertNotIn(
         RpmUnit(unit, relevant_data_keys=unit.keys()),
         RpmUnit.list(self.consumer_cli)
     )
Example #8
0
 def test_06_assert_nonexisten_unit_install(self):
     # https://bugzilla.redhat.com/show_bug.cgi?id=1062725
     # TODO parse callreport,taskreport and assert that in progress report result is false
     unit = {'name': '__NO_SUCH_UNIT__'}
     rpm = RpmUnit(unit, relevant_data_keys=unit.keys())
     with self.pulp.asserting(True):
         task_reports = [
             consumer.install_unit(self.pulp, unit, 'rpm')
             for consumer in self.consumers
         ]
     Task.wait_for_reports(self.pulp, task_reports)