code: def test_dlpack_cuda_not_supported():
      cuda = pytest.importorskip("pyarrow.cuda")
  
      schema = pa.schema([pa.field("f0", pa.int16())])
      a0 = pa.array([1, 2, 3], type=pa.int16())
      batch = pa.record_batch([a0], schema=schema)
  
      cbuf = cuda.serialize_record_batch(batch, cuda.Context(0))
      cbatch = cuda.read_record_batch(cbuf, batch.schema)
      carr = cbatch["f0"]
  
      # CudaBuffers not yet supported
      with pytest.raises(
          NotImplementedError,
          match="DLPack support is implemented "
          "only for buffers on CPU device.",
      ):
          np.from_dlpack(carr)
  
      with pytest.raises(
          NotImplementedError,
          match="DLPack support is implemented "
          "only for buffers on CPU device.",
      ):
          carr.__dlpack_device__()
  
file_path: arrow/python/pyarrow/tests/test_dlpack.py
imports: import ctypes
  from functools import wraps
  import pytest
  import numpy
  import pyarrow
  from pyarrow.vendored.version import Version
label_desc: Use image node_id 6 for calling a global function with example usage: test_dlpack_cuda_not_supported() without return types