Permalink
Browse files

fixed imageScene2D tests

  • Loading branch information...
1 parent 636beda commit b7a0d5464720342640f900d48279e5b2a1dfac13 @bekaus bekaus committed Jul 16, 2012
Showing with 3 additions and 4 deletions.
  1. +3 −4 tests/imageScene2D_tests.py
@@ -36,10 +36,13 @@ def renderScene( self, s):
img = QImage(310,290,QImage.Format_ARGB32_Premultiplied)
p = QPainter(img)
s.render(p)
+ s.joinRendering()
+ s.render(p)
p.end()
return byte_view(img)
def testBasicImageRenderingCapability( self ):
+ import time
aimg = self.renderScene(self.scene)
self.assertTrue(np.all(aimg[:,:,0:3] == self.GRAY))
self.assertTrue(np.all(aimg[:,:,3] == 255))
@@ -60,9 +63,5 @@ def testToggleVisibilityOfOneLayer( self ):
self.assertTrue(np.all(aimg[:,:,0:3] == self.GRAY))
self.assertTrue(np.all(aimg[:,:,3] == 255))
- def tearDown( self ):
- self.scene._renderThread.stop()
- self.app.quit()
-
if __name__ == '__main__':
ut.main()

0 comments on commit b7a0d54

Please sign in to comment.