def test_annotationadaptor(self): """Testing the the annotation adaptor.""" annotation_adaptor = IMarginaliaAnnotatableAdaptor(self.document) self.assertEquals( isinstance(annotation_adaptor, SimpleDocumentAnnotationAdaptor), True, "Unable to find the Annotation Adaptor Implementation.") self.assertEquals(annotation_adaptor.isAnnotatable(), True, "This should return True like a marker interface.") self.assertEquals(annotation_adaptor.getBodyText(), u"body text", "This should return True like a marker interface.")
def test_annotationadaptor(self): """Testing the the annotation adaptor.""" annotation_adaptor = IMarginaliaAnnotatableAdaptor(self.document) self.assertEquals(isinstance(annotation_adaptor, SimpleDocumentAnnotationAdaptor), True, "Unable to find the Annotation Adaptor Implementation.") self.assertEquals(annotation_adaptor.isAnnotatable(), True, "This should return True like a marker interface.") self.assertEquals(annotation_adaptor.getBodyText(), u"body text", "This should return True like a marker interface.")
def getAnnotatedUrl(self): """Returns a boolean True""" obj = IMarginaliaAnnotatableAdaptor(self.context) return obj.getAnnotatedUrl(self.request)
def isAnnotatable(self): """Returns a boolean True""" obj = IMarginaliaAnnotatableAdaptor(self.context) return obj.isAnnotatable()
def getTitle(self): """Returns annotated url.""" obj = IMarginaliaAnnotatableAdaptor(self.context) return obj.getTitle()
def getBaseUrl(self): obj = IMarginaliaAnnotatableAdaptor(self.context) return obj.getAnnotatedUrl(self.request)