def test_real_data(self): files = os.listdir('tests/remote_cache') flags = {"ext_ok": False, "deref_links": False} for f in files: fn = os.path.join('tests/remote_cache', f) upgrader = prezi_upgrader.Upgrader(flags) try: upgrader.process_cached(fn) except: print("Failed to process %s" % fn) raise
def test_remotes(self): uris = [ "https://api.bl.uk/metadata/iiif/ark:/81055/vdc_100054149545.0x000001/manifest.json", "https://d.lib.ncsu.edu/collections/catalog/nubian-message-1992-11-30/manifest", "https://sinai-images.library.ucla.edu/iiif/ark%3A%252F21198%252Fz1bc4wfw/manifest" ] for u in uris: flags = {"deref_links": False} up = prezi_upgrader.Upgrader(flags) res = up.process_uri(u)
def setUp(self): flags = {"ext_ok": False, "deref_links": False} self.upgrader = prezi_upgrader.Upgrader(flags) self.results = self.upgrader.process_cached( 'tests/input_data/collection-basic.json')
def setUp(self): flags = {"ext_ok": False, "deref_links": False} self.upgrader = prezi_upgrader.Upgrader(flags) self.results = self.upgrader.process_cached( 'tests/input_data/manifest-services.json')
def setUp(self): flags = {"ext_ok": False, "deref_links": False} self.upgrader = prezi_upgrader.Upgrader(flags) self.results = self.upgrader.process_cached( 'tests/input_data/manifest-annos.json') self.annotations = self.results['items'][0]['items'][0]['items']