def test_create_delete(self, artifactory): name = 'test-debian-repo' # Remove if exist test_repo = artifactory.find_repository_local(name) if test_repo is not None: test_repo.delete() test_repo = RepositoryLocal(artifactory=artifactory, name=name, packageType=RepositoryLocal.DEBIAN) # CREATE test_repo.create() assert artifactory.find_repository_local(name) is not None assert test_repo.raw['enableDebianSupport'], "Repository is not Debian" # DELETE test_repo.delete() assert artifactory.find_repository_local(name) is None
def find_repository_local(self, name): obj = RepositoryLocal(self, name, packageType=None) if obj.read(): return obj return None