def atest_new_newspaper(): # loading melon should result in two items in the newspapers collection melon = join(test_data, 'batch_mdu_melon') load_batch(melon, test_iiif) newspapers = json.load(open(join(test_iiif, "newspapers.json"))) assert len(newspapers['collections']) == 2
def test_overlay(): # loading lilac should result in two issues being present in the newspaper # collection lilac = join(test_data, 'batch_mdu_lilac') load_batch(lilac, test_iiif) newspaper = json.load(open(join(test_iiif, "sn83009569", "newspaper.json"))) assert len(newspaper['manifests']) == 2
def setup_module(module): # clean up any existing data from previous test run if isdir(test_iiif): shutil.rmtree(test_iiif) os.mkdir(test_iiif) module.batch = load_batch(kale, test_iiif)