

def testOrder(self):

    class MetadataTestNodeA(Gaffer.Node):

        def __init__(self, name='MetadataTestNodeOne'):
            Gaffer.Node.__init__(self, name)
            self['a'] = Gaffer.IntPlug()
    IECore.registerRunTimeTyped(MetadataTestNodeA)

    class MetadataTestNodeB(MetadataTestNodeA):

        def __init__(self, name='MetadataTestNodeOne'):
            MetadataTestNodeA.__init__(self, name)
    IECore.registerRunTimeTyped(MetadataTestNodeB)
    node = MetadataTestNodeB()
    Gaffer.Metadata.registerNodeValue(node, 'nodeSeven', 7)
    Gaffer.Metadata.registerNodeValue(node, 'nodeEight', 8)
    Gaffer.Metadata.registerNodeValue(node, 'nodeNine', 9)
    Gaffer.Metadata.registerNodeValue(MetadataTestNodeB, 'nodeFour', 4)
    Gaffer.Metadata.registerNodeValue(MetadataTestNodeB, 'nodeFive', 5)
    Gaffer.Metadata.registerNodeValue(MetadataTestNodeB, 'nodeSix', 6)
    Gaffer.Metadata.registerNodeValue(MetadataTestNodeA, 'nodeOne', 1)
    Gaffer.Metadata.registerNodeValue(MetadataTestNodeA, 'nodeTwo', 2)
    Gaffer.Metadata.registerNodeValue(MetadataTestNodeA, 'nodeThree', 3)
    self.assertEqual(Gaffer.Metadata.registeredNodeValues(node), ['nodeOne', 'nodeTwo', 'nodeThree', 'nodeFour', 'nodeFive', 'nodeSix', 'nodeSeven', 'nodeEight', 'nodeNine'])
    Gaffer.Metadata.registerPlugValue(node['a'], 'plugSeven', 7)
    Gaffer.Metadata.registerPlugValue(node['a'], 'plugEight', 8)
    Gaffer.Metadata.registerPlugValue(node['a'], 'plugNine', 9)
    Gaffer.Metadata.registerPlugValue(MetadataTestNodeB, 'a', 'plugFour', 4)
    Gaffer.Metadata.registerPlugValue(MetadataTestNodeB, 'a', 'plugFive', 5)
    Gaffer.Metadata.registerPlugValue(MetadataTestNodeB, 'a', 'plugSix', 6)
    Gaffer.Metadata.registerPlugValue(MetadataTestNodeA, 'a', 'plugOne', 1)
    Gaffer.Metadata.registerPlugValue(MetadataTestNodeA, 'a', 'plugTwo', 2)
    Gaffer.Metadata.registerPlugValue(MetadataTestNodeA, 'a', 'plugThree', 3)
    self.assertEqual(Gaffer.Metadata.registeredPlugValues(self['a']), ['plugOne', 'plugTwo', 'plugThree', 'plugFour', 'plugFive', 'plugSix', 'plugSeven', 'plugEight', 'plugNine'])

dataset/ETHPy150Open ImageEngine/gaffer/python/GafferTest/MetadataTest.py MetadataTest.testOrder/VarMisuse@410/713 `node`->`self`