code: def test_get_dummies_index():
      # GH9980, GH8028
      idx = Index(["a|b", "a|c", "b|c"])
      result = idx.str.get_dummies("|")
  
      expected = MultiIndex.from_tuples(
          [(1, 1, 0), (1, 0, 1), (0, 1, 1)], names=("a", "b", "c")
      )
      tm.assert_index_equal(result, expected)
  
imports: import numpy
  from pandas import DataFrame, Index, MultiIndex, Series, _testing
label_desc: Use image node_id 2 for calling a global function with example usage: test_get_dummies_index() without return types