Esempio n. 1
0
    def test_annotation_group(self):
        ec = ElucidateClient(BASE_URI)

        group_id = ec.create_group("test_group")
        ic(group_id)
        assert isinstance(group_id, str)
        assert group_id is not None

        annotation_url = f'{BASE_URI}/group_id/annotation_id'

        group_annotations = self._extracted_from_test_annotation_group_11(
            ec, group_id)
        assert annotation_url not in group_annotations

        annotation_id = AnnotationIdentifier(annotation_url, "")
        success = ec.create_group_annotation(
            group_id=group_id, annotation_identifier=annotation_id)
        assert success == True

        group_annotations = self._extracted_from_test_annotation_group_11(
            ec, group_id)
        assert annotation_url in group_annotations

        success = ec.delete_group_annotation(
            group_id=group_id, annotation_identifier=annotation_id)
        assert success == True

        group_annotations = self._extracted_from_test_annotation_group_11(
            ec, group_id)
        assert annotation_url not in group_annotations
Esempio n. 2
0
 def test_group(self):
     ec = ElucidateClient(BASE_URI)
     group_id = ec.create_group("test_group")
     ic(group_id)
     assert isinstance(group_id, str)
     assert group_id is not None