Skip to content

Commit 3b8b388

Browse files
committed
Arnold tests : Disable problematic tests for Arnold 7 on Mac
These exposed a bug in Arnold 7's render session handling. This could be reproduced with the following simple script : ``` arnold.AiBegin() while True : # Make a universe, do an interactive render. # If we don't do this, then all is well. if True : universe = arnold.AiUniverse() arnold.AiSceneLoad( universe, './render.ass', None ) session = arnold.AiRenderSession( universe ) arnold.AiRenderBegin( session, arnold.AI_RENDER_MODE_CAMERA ) arnold.AiRenderEnd( session ) arnold.AiRenderSessionDestroy( session ) arnold.AiUniverseDestroy( universe ) # Make another universe, and load an ass file. # Occasionally this will fail, either crashing or # not producing any nodes. universe = arnold.AiUniverse() arnold.AiSceneLoad( universe, './load.ass', None ) assert( arnold.AiNodeLookUpByName( universe, "test" ) is not None ) arnold.AiUniverseDestroy( universe ) arnold.AiEnd() ``` We've confirmed that the upcoming Arnold 7.0.0.1 fixes both this simple repro and the original problem in the unit tests. But while that is still pending release, we want to be able to release Gaffer 0.61. Hence we disable the tests for the specific problematic Arnold version.
1 parent c9415fe commit 3b8b388

File tree

2 files changed

+28
-0
lines changed

2 files changed

+28
-0
lines changed

python/GafferArnoldTest/ArnoldRenderTest.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
import inspect
4040
import unittest
4141
import subprocess32 as subprocess
42+
import sys
4243
import threading
4344

4445
import arnold
@@ -68,6 +69,17 @@ def setUp( self ) :
6869

6970
self.__scriptFileName = self.temporaryDirectory() + "/test.gfr"
7071

72+
if (
73+
GafferTest.inCI() and
74+
[ int( v ) for v in arnold.AiGetVersion() ] == [ 7, 0, 0, 0 ] and
75+
sys.platform == "darwin"
76+
) :
77+
# Skipping due to multiple-render-session bugs in Arnold 7.0.0.0. We have
78+
# reported the bug with a small repro and it is confirmed as fixed for the
79+
# upcoming 7.0.0.1 release. It sounds as if the problem exists on Linux too,
80+
# but we have only encountered it on Mac so far.
81+
self.skipTest( "Exposes Arnold bug" )
82+
7183
def tearDown( self ) :
7284

7385
GafferSceneTest.SceneTestCase.tearDown( self )

python/IECoreArnoldTest/RendererTest.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
import ctypes
3838
import json
3939
import os
40+
import sys
4041
import time
4142
import unittest
4243

@@ -53,6 +54,21 @@
5354

5455
class RendererTest( GafferTest.TestCase ) :
5556

57+
def setUp( self ) :
58+
59+
GafferTest.TestCase.setUp( self )
60+
61+
if (
62+
GafferTest.inCI() and
63+
[ int( v ) for v in arnold.AiGetVersion() ] == [ 7, 0, 0, 0 ] and
64+
sys.platform == "darwin"
65+
) :
66+
# Skipping due to multiple-render-session bugs in Arnold 7.0.0.0. We have
67+
# reported the bug with a small repro and it is confirmed as fixed for the
68+
# upcoming 7.0.0.1 release. It sounds as if the problem exists on Linux too,
69+
# but we have only encountered it on Mac so far.
70+
self.skipTest( "Exposes Arnold bug" )
71+
5672
def assertReferSameNode( self, a, b ):
5773
self.assertEqual( arnold.addressof( a.contents ), arnold.addressof( b.contents ) )
5874

0 commit comments

Comments
 (0)