( self )
| 40 | class ParameterAlgoTest( unittest.TestCase ) : |
| 41 | |
| 42 | def testFindClasses( self ) : |
| 43 | |
| 44 | p = IECore.CompoundParameter( |
| 45 | |
| 46 | name = "p", |
| 47 | description = "", |
| 48 | |
| 49 | members = [ |
| 50 | |
| 51 | IECore.CompoundParameter( |
| 52 | |
| 53 | name = "q", |
| 54 | description = "", |
| 55 | members = [ |
| 56 | |
| 57 | IECore.ClassVectorParameter( |
| 58 | |
| 59 | "cv", |
| 60 | "d", |
| 61 | "IECORE_OP_PATHS", |
| 62 | [ |
| 63 | ( "mult", os.path.join( "maths", "multiply" ), 2 ), |
| 64 | ( "coIO", "compoundObjectInOut", 2 ), |
| 65 | ] |
| 66 | |
| 67 | ), |
| 68 | |
| 69 | IECore.ClassParameter( |
| 70 | |
| 71 | "c", |
| 72 | "d", |
| 73 | "IECORE_OP_PATHS", |
| 74 | "classParameterTest", 1 |
| 75 | |
| 76 | ) |
| 77 | |
| 78 | ] |
| 79 | |
| 80 | ), |
| 81 | |
| 82 | |
| 83 | ] |
| 84 | |
| 85 | ) |
| 86 | |
| 87 | p["q"]["c"]["cp"].setClass( "classVectorParameterTest", 1 ) |
| 88 | |
| 89 | p["q"]["c"]["cp"]["cv"].setClasses( [ |
| 90 | ( "mult", os.path.join( "maths", "multiply" ), 2 ), |
| 91 | ( "coIO", "compoundObjectInOut", 2 ) |
| 92 | ] ) |
| 93 | |
| 94 | c = IECore.ParameterAlgo.findClasses( p ) |
| 95 | |
| 96 | expected = [ |
| 97 | |
| 98 | { |
| 99 | "parent" : p["q"]["cv"], |
nothing calls this directly
no test coverage detected