code: def test_apply_gap_for_expanding_primitives_throws_error_when_given_string_offset(
      window_series_pd,
  ):
      error_msg = "String offsets are not supported for the gap parameter in Expanding primitives"
      with pytest.raises(TypeError, match=error_msg):
          _apply_gap_for_expanding_primitives(
              window_series_pd, gap="2H"
          )
  
file_path: featuretools/featuretools/tests/primitive_tests/transform_primitive_tests/test_expanding_primitives.py
imports: import numpy
  import pandas
  import pytest
  from featuretools.primitives.standard.transform.time_series.expanding import ExpandingCount, ExpandingMax, ExpandingMean, ExpandingMin, ExpandingSTD, ExpandingTrend
  from featuretools.primitives.standard.transform.time_series.utils import _apply_gap_for_expanding_primitives
  from featuretools.utils import calculate_trend
label_desc: Use image node_id 9 for calling a global function with example usage: test_apply_gap_for_expanding_primitives_throws_error_when_given_string_offset(window_series_pd) without return types