

def testArbitraryValues(self):
    add = GafferTest.AddNode()
    self.assertEqual(Gaffer.Metadata.nodeValue(add, 'aKey'), None)
    self.assertEqual(Gaffer.Metadata.plugValue(add['op1'], 'aKey'), None)
    Gaffer.Metadata.registerNodeValue(GafferTest.AddNode, 'aKey', 'something')
    Gaffer.Metadata.registerPlugValue(GafferTest.AddNode, 'op*', 'aKey', 'somethingElse')
    self.assertEqual(Gaffer.Metadata.nodeValue(add, 'aKey'), 'something')
    self.assertEqual(Gaffer.Metadata.plugValue(add['op1'], 'aKey'), 'somethingElse')

dataset/ETHPy150Open ImageEngine/gaffer/python/GafferTest/MetadataTest.py MetadataTest.testArbitraryValues/original