code: def test_nunique_categorical():
      # GH#18051
      ser = Series(Categorical([]))
      assert ser.nunique() == 0
  
      ser = Series(Categorical([np.nan]))
      assert ser.nunique() == 0
  
label_desc: Use image node_id 2 for calling a global function with example usage: test_nunique_categorical() without return types