code: def test_dtype_by(df):
      """Check dtype for by."""
      with pytest.raises(TypeError):
          df.groupby_topk(by={"result"}, column="age", k=2)
  
file_path: pyjanitor/tests/functions/test_groupby_topk.py
imports: import pandas
  import pytest
  from pandas.testing import assert_frame_equal
label_desc: Use image node_id 2 for calling a global function with example usage: test_dtype_by(df) without return types