class_docstr: Swap-in HDF5 File Handler.
class_docstr_tok: ["Swap-in","HDF5","File","Handler","."]
docstr: Make test data.
docstr_tok: ["Make","test","data","."]
code: def make_test_data(self, cwl, ch, prefix, dims, file_type):
      """Make test data."""
      if prefix == "CAL":
          data = xr.DataArray(
              da.from_array(
                  (np.arange(10.0) + 1.0) / 10.0, [dims[0] * dims[1]]
              ),
              attrs={
                  "Slope": np.array(1.0),
                  "Intercept": np.array(0.0),
                  "FillValue": np.array(-65535.0),
                  "units": "NUL",
                  "center_wavelength": "{}um".format(cwl).encode(
                      "utf-8"
                  ),
                  "band_names": "band{}(band number is range from 1 to 14)".format(
                      ch
                  ).encode(
                      "utf-8"
                  ),
                  "long_name": "Calibration table of {}um Channel".format(
                      cwl
                  ).encode(
                      "utf-8"
                  ),
                  "valid_range": np.array([0, 1.5]),
              },
              dims="_const",
          )
  
      elif prefix == "NOM":
          data = xr.DataArray(
              da.from_array(
                  np.arange(10, dtype=np.uint16).reshape((2, 5)) + 1,
                  [dim for dim in dims],
              ),
              attrs={
                  "Slope": np.array(1.0),
                  "Intercept": np.array(0.0),
                  "FillValue": np.array(65535),
                  "units": "DN",
                  "center_wavelength": "{}um".format(cwl).encode(
                      "utf-8"
                  ),
                  "band_names": "band{}(band number is range from 1 to 14)".format(
                      ch
                  ).encode(
                      "utf-8"
                  ),
                  "long_name": "Calibration table of {}um Channel".format(
                      cwl
                  ).encode(
                      "utf-8"
                  ),
                  "valid_range": np.array([0, 4095]),
              },
              dims=("_RegLength", "_RegWidth"),
          )
  
      elif prefix == "GEO":
          data = xr.DataArray(
              da.from_array(
                  np.arange(0.0, 360.0, 36.0, dtype=np.float32).reshape(
                      (2, 5)
                  ),
                  [dim for dim in dims],
              ),
              attrs={
                  "Slope": np.array(1.0),
                  "Intercept": np.array(0.0),
                  "FillValue": np.array(65535.0),
                  "units": "NUL",
                  "band_names": "NUL",
                  "valid_range": np.array([0.0, 360.0]),
              },
              dims=("_RegLength", "_RegWidth"),
          )
  
      elif prefix == "COEF":
          if file_type == "500":
              data = self._create_coeff_array(1)
  
          elif file_type == "1000":
              data = self._create_coeff_array(3)
  
          elif file_type == "2000":
              data = self._create_coeff_array(7)
  
          elif file_type == "4000":
              data = self._create_coeff_array(14)
  
      return data
  
imports: import os
  from unittest import mock
  import dask.array
  import numpy
  import pytest
  import xarray
  from satpy.tests.reader_tests.test_hdf5_utils import FakeHDF5FileHandler
label_desc: Use image node_id 1 for calling the FakeHDF5FileHandler2 obj's underlying member method code with example usage: obj.make_test_data(cwl, ch, prefix, dims, file_type) and returns: data