code: def test_agg_two_groupers_ordered(df):
      order = {"b": ["h", "g", "f"], "x": [3, 2, 1]}
      res = GroupBy(order).agg(
          df, {"a": "min", "y": lambda x: x.iloc[0]}
      )
      assert_array_equal(res.index, [0, 1, 2, 3, 4, 5, 6, 7, 8])
      assert_array_equal(res.columns, ["a", "b", "x", "y"])
      assert_array_equal(
          res["b"], ["h", "h", "h", "g", "g", "g", "f", "f", "f"]
      )
      assert_array_equal(res["x"], [3, 2, 1, 3, 2, 1, 3, 2, 1])
  
      T, F = True, False
      assert_array_equal(res["a"].isna(), [F, T, F, T, T, F, T, F, T])
      assert_array_equal(res["a"].dropna(), ["b", "a", "a", "a"])
      assert_array_equal(res["y"].dropna(), [0.5, 0.3, 0.2, 0.8])
  
file_path: seaborn/tests/_core/test_groupby.py
imports: import numpy
  import pandas
  import pytest
  from numpy.testing import assert_array_equal
  from seaborn._core.groupby import GroupBy
label_desc: Use image node_id 8 for calling a global function with example usage: test_agg_two_groupers_ordered(df) without return types