code: def test_df_cat_sort_index():
      df = cudf.DataFrame()
      df["a"] = pd.Categorical(
          list("aababcabbc"), categories=list("abc")
      )
      df["b"] = np.arange(len(df))
  
      got = df.set_index("a").sort_index()
      expect = df.to_pandas().set_index("a").sort_index()
  
      assert_eq(got, expect)
  
imports: import operator
  import string
  import warnings
  from contextlib import contextmanager
  from textwrap import dedent
  import numpy
  import pandas
  import pytest
  import cudf
  from cudf.core._compat import PANDAS_GE_134
  from cudf.testing._utils import NUMERIC_TYPES, assert_eq, assert_exceptions_equal, expect_warning_if
label_desc: Use image node_id 12 for calling a global function with example usage: test_df_cat_sort_index() without return types