code: def test_plot_tree(breast_cancer_split):
      X_train, _, y_train, _ = breast_cancer_split
      gbm = lgb.LGBMClassifier(
          n_estimators=10, num_leaves=3, verbose=-1
      )
      gbm.fit(X_train, y_train)
  
      with pytest.raises(IndexError):
          lgb.plot_tree(gbm, tree_index=83)
  
      ax = lgb.plot_tree(
          gbm, tree_index=3, figsize=(15, 8), show_info=["split_gain"]
      )
      assert isinstance(ax, matplotlib.axes.Axes)
      w, h = ax.axes.get_figure().get_size_inches()
      assert int(w) == 15
      assert int(h) == 8
  
imports: import numpy
  import pandas
  import pytest
  from sklearn.model_selection import train_test_split
  import lightgbm
  from lightgbm.compat import GRAPHVIZ_INSTALLED, MATPLOTLIB_INSTALLED, PANDAS_INSTALLED, pd_DataFrame
  from .utils import load_breast_cancer, make_synthetic_regression
label_desc: Use image node_id 7 for calling a global function with example usage: test_plot_tree(breast_cancer_split) without return types