code: def test_duplicate_sf_names():
      groups = pd.DataFrame(
          np.stack([g_2, g_3], axis=1), columns=["A", "A"]
      )
      msg = "Detected duplicate feature name: 'A'"
      with pytest.raises(ValueError) as execInfo:
          _ = metrics.MetricFrame(
              metrics=skm.recall_score,
              y_true=y_t,
              y_pred=y_p,
              sensitive_features=groups,
          )
      assert execInfo.value.args[0] == msg
  
file_path: fairlearn/test/unit/metrics/test_metricframe_smoke.py
imports: from test.unit.input_convertors import conversions_for_1d
  import numpy
  import pandas
  import pytest
  import sklearn.metrics
  import fairlearn.metrics
  from .data_for_test import g_1, g_2, g_3, g_4, s_w, y_p, y_t
label_desc: Use image node_id 7 for calling a global function with example usage: test_duplicate_sf_names() without return types