class_docstr: Checks the full filesystem resolution functionality, exercising each URL interpretation case.
docstr: Various error cases that result in exception raised.
docstr_tok: ["Various","error","cases","that","result","in","exception","raised","."]
code: def test_error_url_cases(self):
      """Various error cases that result in exception raised."""
      # Case 1: Schemeless path asserts
      with self.assertRaises(ValueError):
          FilesystemResolver(ABS_PATH, {})
  
      # Case 4b: HDFS default path case with NO defaultFS
      with self.assertRaises(RuntimeError):
          FilesystemResolver("hdfs:///some/path", {})
  
      # Case 4b: Using `default` as host, while apparently a pyarrow convention, is NOT valid
      with self.assertRaises(ArrowIOError):
          FilesystemResolver("hdfs://default", {})
  
      # Case 5: other schemes result in ValueError; urlparse to cover an else branch!
      with self.assertRaises(ValueError):
          FilesystemResolver(urlparse("unknown://foo/bar"), {})
  
      # s3 paths must have the bucket as the netloc
      with self.assertRaises(ValueError):
          FilesystemResolver(urlparse("s3:///foo/bar"), {})
  
      # GCS paths must have the bucket as the netloc
      with self.assertRaises(ValueError):
          FilesystemResolver(urlparse("gcs:///foo/bar"), {})
  
imports: import unittest
  import dill
  from pyarrow.filesystem import LocalFileSystem
  from pyarrow.lib import ArrowIOError
  from six.moves.urllib.parse import urlparse
  import gcsfs
  import s3fs
  from petastorm.fs_utils import FilesystemResolver, get_filesystem_and_path_or_paths
  from petastorm.hdfs.tests.test_hdfs_namenode import HC, MockHadoopConfiguration, MockHdfs, MockHdfsConnector
label_desc: Use image node_id 3 for calling the FilesystemResolverTest obj's underlying member method code with example usage: obj.test_error_url_cases() without return types