code: def testCachedClassProperty(self):
      log = []  # log all calls to `MyClass.value`.
  
      class MyClass(object):
          @decorator_utils.cached_classproperty
          def value(cls):  # pylint: disable=no-self-argument
              log.append(cls)
              return cls.__name__
  
      class MySubclass(MyClass):
          pass
  
      # Property is computed first time it is accessed.
      self.assertLen(log, 0)
      self.assertEqual(MyClass.value, "MyClass")
      self.assertEqual(log, [MyClass])
  
      # Cached values are used on subsequent accesses.
      self.assertEqual(MyClass.value, "MyClass")
      self.assertEqual(MyClass.value, "MyClass")
      self.assertEqual(log, [MyClass])
  
      # The wrapped method is called for each subclass.
      self.assertEqual(MySubclass.value, "MySubclass")
      self.assertEqual(log, [MyClass, MySubclass])
      self.assertEqual(MySubclass.value, "MySubclass")
      self.assertEqual(MySubclass.value, "MySubclass")
      self.assertEqual(log, [MyClass, MySubclass])
  
      # The property can also be accessed via an instance.
      self.assertEqual(MyClass().value, "MyClass")
      self.assertEqual(MySubclass().value, "MySubclass")
      self.assertEqual(log, [MyClass, MySubclass])
  
      # Attempts to modify the property via an instance will fail.
      with self.assertRaises(AttributeError):
          MyClass().value = 12
      with self.assertRaises(AttributeError):
          del MyClass().value
  
imports: import functools
  from tensorflow.python.platform import test
  from tensorflow.python.platform import tf_logging
  from tensorflow.python.util import decorator_utils
label_desc: Use image node_id 1 for calling the CachedClassPropertyTest obj's underlying member method code with example usage: obj.testCachedClassProperty() and returns: cls