def test_05_importer_update_unexistent_repo(self): self.pulp.send( self.repo1.request('PUT', path=path_join(Importer.path, 'yum_importer'), data={"importer_config": { "num_units": 10 }})) self.assertPulp(code=404)
def test_05_distributor_update_unexistent_repo(self): self.pulp.send( self.repo1.request( 'PUT', path=path_join(Distributor.path, 'yum_distributor'), data={"distributor_config": { "relative_url": "my_url" }})) self.assertPulp(code=404)
def test_03_applicabilty_non_existing_consumer(self): #Generate Content Applicability for a single Consumer #if a consumer with given consumer_id does not exist self.pulp.send( Request( 'POST', path_join( Consumer.path, '/NonExistingConsumerID/actions/content/regenerate_applicability/' ))) self.assertPulp(code=404)
def test_01_orphan_info_data_integrity(self): info = Orphans.info(self.pulp) orphans = Orphans.get(self.pulp) self.assertPulpOK() for orphan_type_name in orphans.keys(): # reported count info is the same as the orphans counted self.assertEqual(len(orphans[orphan_type_name]), info[orphan_type_name]['count']) orphan_type = UnitFactory.type_map.orphans[orphan_type_name] # '_href' is correct self.assertEqual(pulp_auto.path_join(pulp_auto.path, orphan_type.path), info[orphan_type_name]['_href']) # all orphans are of the same type for orphan in orphans[orphan_type_name]: self.assertTrue(isinstance(orphan, orphan_type), "different type: %s, %s" % (orphan_type_name, orphan.type_id))
def test_05_distributor_update_unexistent_repo(self): self.pulp.send(self.repo1.request('PUT', path=path_join(Distributor.path, 'yum_distributor'), data={"distributor_config": {"relative_url": "my_url"}})) self.assertPulp(code=404)
def test_05_importer_update_unexistent_repo_1078833(self): # https://bugzilla.redhat.com/show_bug.cgi?id=1078833 self.pulp.send(self.repo1.request('PUT', path=path_join(Importer.path, 'yum_importer'), data={"importer_config": {"num_units": 10}})) self.assertPulp(code=404)
def test_01_view_orphaned_content_invalid_type_1092450(self): # https://bugzilla.redhat.com/show_bug.cgi?id=1092450 self.pulp.send(Request('GET', path_join(Orphans.path, 'invalid_type'))) self.assertPulp(code=404)
def get(cls, pulp, id): '''no GET method allowed (405)''' assert pulp.send(Request('GET', path_join(cls.path, id))) == ResponseLike(405) raise TypeError('Uploads do not support GET method')
def test_03_applicabilty_non_existing_consumer(self): #Generate Content Applicability for a single Consumer #if a consumer with given consumer_id does not exist self.pulp.send(Request('POST', path_join(Consumer.path,'/NonExistingConsumerID/actions/content/regenerate_applicability/'))) self.assertPulp(code=404)
def test_05_importer_update_unexistent_repo(self): self.pulp.send(self.repo1.request('PUT', path=path_join(Importer.path, 'yum_importer'), data={"importer_config": {"num_units": 10}})) self.assertPulp(code=404)