code: def test_snirf_nirsport2():
      """Test reading SNIRF files."""
      raw = read_raw_snirf(nirx_nirsport2_103, preload=True)
  
      # Test data import
      assert raw._data.shape == (92, 84)
      assert_almost_equal(raw.info["sfreq"], 7.6, decimal=1)
  
      # Test channel naming
      assert raw.info["ch_names"][:4] == [
          "S1_D1 760",
          "S1_D3 760",
          "S1_D9 760",
          "S1_D16 760",
      ]
      assert raw.info["ch_names"][24:26] == ["S8_D15 760", "S8_D20 760"]
  
      # Test frequency encoding
      assert raw.info["chs"][0]["loc"][9] == 760
      assert raw.info["chs"][-1]["loc"][9] == 850
  
      assert sum(short_channels(raw.info)) == 16
  
imports: import shutil
  import numpy
  import pytest
  from numpy.testing import assert_allclose, assert_almost_equal, assert_equal
  from mne._fiff.constants import FIFF
  from mne.datasets.testing import data_path, requires_testing_data
  from mne.io import read_raw_nirx, read_raw_snirf
  from mne.io.tests.test_raw import _test_raw_reader
  from mne.preprocessing.nirs import _reorder_nirx, beer_lambert_law, optical_density, short_channels, source_detector_distances
  from mne.transforms import _get_trans, apply_trans
  from mne.utils import catch_logging
label_desc: Use image node_id 7 for calling a global function with example usage: test_snirf_nirsport2() without return types