code: def test_aggregate_str_cat(setup, check_ref_counts):
      agg_fun = lambda x: x.str.cat(sep="_", na_rep="NA")
  
      rs = np.random.RandomState(0)
      raw_df = pd.DataFrame(
          {
              "a": rs.choice(["A", "B", "C"], size=(100,)),
              "b": rs.choice(
                  [None, "alfa", "bravo", "charlie"], size=(100,)
              ),
          }
      )
  
      mdf = md.DataFrame(raw_df, chunk_size=13)
  
      r = mdf.agg(agg_fun)
      pd.testing.assert_series_equal(
          r.execute().fetch(), raw_df.agg(agg_fun)
      )
  
      raw_series = pd.Series(
          rs.choice([None, "alfa", "bravo", "charlie"], size=(100,))
      )
  
      ms = md.Series(raw_series, chunk_size=13)
  
      r = ms.agg(agg_fun)
      assert r.execute().fetch() == raw_series.agg(agg_fun)
  
imports: from typing import NamedTuple
  import numpy
  import pytest
  import pandas
  from ....None import dataframe
  from ....config import option_context
  from ....session import get_default_session
  from ....tests.core import require_cudf, require_cupy
  from ....utils import lazy_import, pd_release_version
  from ...None import CustomReduction, NamedAgg
  from ...base import to_gpu
label_desc: Use image node_id 21 for calling a global function with example usage: test_aggregate_str_cat(setup, check_ref_counts) without return types