class_docstr: Test the transform function (validate and dispatch).
docstr: Test that the device transform returns errors.
code: def test_device_transform_error(self, valid_transform):
      """Test that the device transform returns errors."""
  
      with pytest.raises(
          TransformError,
          match="Device transform does not support informative transforms.",
      ):
          dispatched_transform = transform(
              valid_transform, is_informative=True
          )
          dispatched_transform(dev, index=0)
  
      with pytest.raises(
          TransformError,
          match="Device transform does not support final transforms.",
      ):
          dispatched_transform = transform(
              valid_transform, final_transform=True
          )
          dispatched_transform(dev, index=0)
  
      with pytest.raises(
          TransformError,
          match="Device transform does not support expand transforms.",
      ):
          dispatched_transform = transform(
              valid_transform, expand_transform=valid_transform
          )
          dispatched_transform(dev, index=0)
  
imports: from typing import Sequence, Callable
  from functools import partial
  import pytest
  import pennylane
  from pennylane.transforms.core import transform, TransformError, TransformContainer
label_desc: Use image node_id 20 for calling the TestTransformDispatcher obj's underlying member method code with example usage: obj.test_device_transform_error(valid_transform) without return types