code: def test_stream_capture_failure_curand(self):
      s = cupy.cuda.Stream(non_blocking=True)
  
      with s:
          s.begin_capture()
          with pytest.raises(NotImplementedError) as e:
              cupy.random.random(100)
          assert "cuRAND" in str(e.value)
          s.end_capture()
  
      # check s left the capture mode and permits normal usage
      assert not s.is_capturing()
      s.synchronize()
  
imports: import pytest
  import cupy
  from cupy import cuda
  from cupy import testing
  import cupyx
label_desc: Use image node_id 18 for calling the TestGraph obj's underlying member method code with example usage: obj.test_stream_capture_failure_curand() without return types