code: def test_concat_duplicate_indices_raise(self):
      # GH 45888: test raise for concat DataFrames with duplicate indices
      # https://github.com/pandas-dev/pandas/issues/36263
      df1 = DataFrame(
          np.random.default_rng(2).standard_normal(5),
          index=[0, 1, 2, 3, 3],
          columns=["a"],
      )
      df2 = DataFrame(
          np.random.default_rng(2).standard_normal(5),
          index=[0, 1, 2, 2, 4],
          columns=["b"],
      )
      msg = "Reindexing only valid with uniquely valued Index objects"
      with pytest.raises(InvalidIndexError, match=msg):
          concat([df1, df2], axis=1)
  
imports: from collections import abc, deque
  from collections.abc import Iterator
  from datetime import datetime
  from decimal import Decimal
  import numpy
  import pytest
  from pandas.errors import InvalidIndexError
  import pandas
  from pandas import DataFrame, Index, MultiIndex, PeriodIndex, Series, concat, date_range
  import pandas._testing
  from pandas.core.arrays import SparseArray
  from pandas.tests.extension.decimal import to_decimal
label_desc: Use image node_id 25 for calling the TestConcatenate obj's underlying member method code with example usage: obj.test_concat_duplicate_indices_raise() without return types