code: def test_get_validated_path_with_compression_fn():
      compression_fns = ["gzip", "lzma", "bz2"]
  
      no_extension_filepath = "dummy_file"
  
      expected_no_ext_gzip_filepath = "dummy_file.gz"
      expected_no_ext_lzma_filepath = "dummy_file.lzma"
      expected_no_ext_bz2_filepath = "dummy_file.bz2"
      assert (
          compression_utils.get_validated_path(
              no_extension_filepath, compression_fns[0]
          )
          == expected_no_ext_gzip_filepath
      )
      assert (
          compression_utils.get_validated_path(
              no_extension_filepath, compression_fns[1]
          )
          == expected_no_ext_lzma_filepath
      )
      assert (
          compression_utils.get_validated_path(
              no_extension_filepath, compression_fns[2]
          )
          == expected_no_ext_bz2_filepath
      )
  
      single_extension_filepath = "dummy_file.pkl"
  
      expected_pkl_gzip_filepath = "dummy_file.pkl.gz"
      expected_pkl_lzma_filepath = "dummy_file.pkl.lzma"
      expected_pkl_bz2_filepath = "dummy_file.pkl.bz2"
      assert (
          compression_utils.get_validated_path(
              single_extension_filepath, compression_fns[0]
          )
          == expected_pkl_gzip_filepath
      )
      assert (
          compression_utils.get_validated_path(
              single_extension_filepath, compression_fns[1]
          )
          == expected_pkl_lzma_filepath
      )
      assert (
          compression_utils.get_validated_path(
              single_extension_filepath, compression_fns[2]
          )
          == expected_pkl_bz2_filepath
      )
  
      multiple_extension_filepath = "dummy_file.fake-foo.zip.pkl"
  
      expected_multi_gzip_filepath = "dummy_file.fake-foo.zip.pkl.gz"
      expected_multi_lzma_filepath = "dummy_file.fake-foo.zip.pkl.lzma"
      expected_multi_bz2_filepath = "dummy_file.fake-foo.zip.pkl.bz2"
      assert (
          compression_utils.get_validated_path(
              multiple_extension_filepath, compression_fns[0]
          )
          == expected_multi_gzip_filepath
      )
      assert (
          compression_utils.get_validated_path(
              multiple_extension_filepath, compression_fns[1]
          )
          == expected_multi_lzma_filepath
      )
      assert (
          compression_utils.get_validated_path(
              multiple_extension_filepath, compression_fns[2]
          )
          == expected_multi_bz2_filepath
      )
  
imports: from autogluon.common.utils import compression_utils
label_desc: Use image node_id 2 for calling a global function with example usage: test_get_validated_path_with_compression_fn() without return types