class_docstr: Swap-in NetCDF4 File Handler.
class_docstr_tok: ["Swap-in","NetCDF4","File","Handler","."]
docstr: Mimic reader input file content.
docstr_tok: ["Mimic","reader","input","file","content","."]
code: def get_test_content(self, filename, filename_info, filetype_info):
      """Mimic reader input file content."""
      file_content = {
          "/attr/Platform_Name": filename_info["platform_shortname"],
          "/attr/Element_Resolution": 2.0,
          "/attr/Line_Resolution": 2.0,
          "/attr/Subsatellite_Longitude": -70.2
          if "GOES" in filename_info["platform_shortname"]
          else 140.65,
          "pixel_longitude": DEFAULT_LON_DATA,
          "pixel_longitude/attr/scale_factor": 1.0,
          "pixel_longitude/attr/add_offset": 0.0,
          "pixel_longitude/shape": DEFAULT_FILE_SHAPE,
          "pixel_longitude/attr/_FillValue": np.nan,
          "pixel_latitude": DEFAULT_LAT_DATA,
          "pixel_latitude/attr/scale_factor": 1.0,
          "pixel_latitude/attr/add_offset": 0.0,
          "pixel_latitude/shape": DEFAULT_FILE_SHAPE,
          "pixel_latitude/attr/_FillValue": np.nan,
      }
      sensor = {
          "HIMAWARI-8": "himawari8",
          "GOES-17": "goesr",
          "GOES-16": "goesr",
          "GOES-13": "goes",
          "GOES-14": "goes",
          "GOES-15": "goes",
      }[filename_info["platform_shortname"]]
      file_content["/attr/Sensor_Name"] = sensor
  
      if filename_info["platform_shortname"] == "HIMAWARI-8":
          file_content["pixel_longitude"] = DEFAULT_LON_DATA + 130.0
  
      file_content["variable1"] = DEFAULT_FILE_DATA.astype(np.float32)
      file_content["variable1/attr/_FillValue"] = -1
      file_content["variable1/attr/scale_factor"] = 1.0
      file_content["variable1/attr/add_offset"] = 0.0
      file_content["variable1/attr/units"] = "1"
      file_content["variable1/shape"] = DEFAULT_FILE_SHAPE
  
      # data with fill values
      file_content["variable2"] = np.ma.masked_array(
          DEFAULT_FILE_DATA.astype(np.float32),
          mask=np.zeros_like(DEFAULT_FILE_DATA),
      )
      file_content["variable2"].mask[::5, ::5] = True
      file_content["variable2/attr/_FillValue"] = -1
      file_content["variable2/attr/scale_factor"] = 1.0
      file_content["variable2/attr/add_offset"] = 0.0
      file_content["variable2/attr/units"] = "1"
      file_content["variable2/shape"] = DEFAULT_FILE_SHAPE
  
      # category
      file_content["variable3"] = DEFAULT_FILE_DATA.astype(np.byte)
      file_content["variable3/attr/_FillValue"] = -128
      file_content[
          "variable3/attr/flag_meanings"
      ] = "clear water supercooled mixed ice unknown"
      file_content["variable3/attr/flag_values"] = [0, 1, 2, 3, 4, 5]
      file_content["variable3/attr/units"] = "1"
      file_content["variable3/shape"] = DEFAULT_FILE_SHAPE
  
      attrs = ("_FillValue", "flag_meanings", "flag_values", "units")
      convert_file_content_to_data_array(
          file_content, attrs=attrs, dims=("z", "lines", "elements")
      )
      return file_content
  
file_path: satpy/satpy/tests/reader_tests/test_geocat.py
imports: import os
  import unittest
  from unittest import mock
  import numpy
  from satpy.tests.reader_tests.test_netcdf_utils import FakeNetCDF4FileHandler
  from satpy.tests.utils import convert_file_content_to_data_array
label_desc: Use image node_id 1 for calling the FakeNetCDF4FileHandler2 obj's underlying member method code with example usage: obj.get_test_content(filename, filename_info, filetype_info) and returns: file_content