def test_cannot_ingest_published(self): resource = resourceInfoType_model.objects.get(pk=self.resource_id) resource.storage_object.publication_status = PUBLISHED resource.storage_object.save() ingest_resources(None, None, (resource,)) self.assertEquals("published", resource.publication_status())
def test_can_ingest_internal(self): resource = resourceInfoType_model.objects.get(pk=self.resource_id) resource.storage_object.publication_status = INTERNAL resource.storage_object.save() ingest_resources(None, None, (resource,)) self.assertEquals("ingested", resource.publication_status())