def testUnloadCheckPtr(self): img = ImageI() assert img.isLoaded() assert img.getDetails() # details are auto instantiated assert not img.getName() # no other single-valued field is img.unload() assert not img.isLoaded() pytest.raises(omero.UnloadedEntityException, img.getDetails)
def testUnloadCheckPtr(self): img = ImageI() self.assert_(img.isLoaded()) self.assert_(img.getDetails()) # details are auto instantiated self.assert_(not img.getName()) # no other single-valued field is img.unload() self.assert_(not img.isLoaded()) self.assertRaises(omero.UnloadedEntityException, img.getDetails)
def testUnloadedCtor(self): img = ImageI(rlong(1), False) assert not img.isLoaded() try: assert img.sizeOfDatasetLinks() < 0 assert False, "Should throw" except: # Is true, but can't test it. pass
def testUnloadedCtor(self): img = ImageI(rlong(1), False) self.assert_(not img.isLoaded()) try: self.assert_(img.sizeOfDatasetLinks() < 0) self.fail("Should throw") except: # Is true, but can't test it. pass
def testUnloadedCtor(self): img = ImageI(rlong(1), False) assert not img.isLoaded() try: assert img.sizeOfDatasetLinks() < 0 assert False, "Should throw" except: # Is true, but can't test it. pass
def testUnloadedCtor(self): img = ImageI(rlong(1),False) self.assert_( not img.isLoaded() ) try: self.assert_( img.sizeOfDatasetLinks() < 0 ) self.fail("Should throw") except: # Is true, but can't test it. pass
def testGetAttrGood(self): i = ImageI() assert i.loaded assert i.isLoaded() assert not i.name i.name = rstring("name") assert i.name i.setName(None) assert not i.getName() i.copyAnnotationLinks() i.linkAnnotation(omero.model.BooleanAnnotationI())
def testGetAttrGood(self): i = ImageI() self.assert_(i.loaded) self.assert_(i.isLoaded()) self.assert_(not i.name) i.name = rstring("name") self.assert_(i.name) i.setName(None) self.assert_(not i.getName()) i.copyAnnotationLinks() i.linkAnnotation(omero.model.BooleanAnnotationI())
def testSimpleCtor(self): img = ImageI() assert img.isLoaded() assert img.sizeOfPixels() >= 0
def testSimpleCtor(self): img = ImageI() self.assert_(img.isLoaded()) self.assert_(img.sizeOfPixels() >= 0)