<caseResult _class='hudson.tasks.junit.CaseResult'><age>4</age><className>OmeroPy.test.integration.gatewaytest.test_annotation</className><duration>1.482</duration><errorDetails>KeyError: None</errorDetails><errorStackTrace>author_testimg_generated = &lt;_ImageWrapper id=5674&gt;

    def testLongAnnotation(author_testimg_generated):
&gt;       _testAnnotation(author_testimg_generated,
                        omero.gateway.LongAnnotationWrapper,
                        TESTANN_NS, int(1000))

test/integration/gatewaytest/test_annotation.py:167: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

obj = &lt;_ImageWrapper id=5674&gt;
annclass = &lt;class 'omero.gateway.LongAnnotationWrapper'&gt;
ns = 'omero.gateway.test_annotation', value = 1000, sameOwner = False
testOwner = None

    def _testAnnotation(obj, annclass, ns, value, sameOwner=False,
                        testOwner=None):
        gateway = obj._conn
        # Make sure it doesn't yet exist
        obj.removeAnnotations(ns)
        assert obj.getAnnotation(ns) is None
        # Create new, link and check
        ann = annclass(gateway)
        ann.setNs(ns)
        ann.setValue(value)
        if sameOwner:
            obj.linkAnnotation(ann, sameOwner=True)
        else:
            # checks that default sameOwner=False
            obj.linkAnnotation(ann)
        ann = obj.getAnnotation(ns)
        # Make sure the group for the annotation is the same as the original
        # object. (#120)
        assert ann.getDetails().getGroup() == obj.getDetails().getGroup()
        tval = hasattr(value, 'val') and value.val or value
        assert ann.getValue() == value, '%s != %s' % (str(ann.getValue()),
                                                      str(tval))
        assert ann.getNs() == ns,  '%s != %s' % (str(ann.getNs()), str(ns))
        if testOwner is not None:
            testOwner(obj, ann)
        # test conn.countAnnotations()
        counts = gateway.countAnnotations(obj.OMERO_CLASS, [obj.id])
        assert counts is not None
        # Timestamp and Boolean not included in counts
        if annclass.OMERO_CLASS not in ["TimestampAnnotation",
                                        "BooleanAnnotation",
                                        # LongAnnotation is only for 'rating'
                                        "LongAnnotation"]:
&gt;           assert counts[annclass.OMERO_CLASS] &gt;= 1.   # e.g. TagAnnotation: 1
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
E           KeyError: None

test/integration/gatewaytest/test_annotation.py:59: KeyError</errorStackTrace><failedSince>71</failedSince><name>testLongAnnotation</name><properties></properties><skipped>false</skipped><status>FAILED</status></caseResult>