code: def test_latex_pkg_already_loaded(preamble):
      plt.rcParams["text.latex.preamble"] = preamble
      fig = plt.figure()
      fig.text(0.5, 0.5, "hello, world", usetex=True)
      fig.canvas.draw()
  
imports: from tempfile import TemporaryFile
  import numpy
  from packaging.version import parse
  import pytest
  import matplotlib
  from matplotlib import dviread
  from matplotlib.testing import _has_tex_package
  from matplotlib.testing.decorators import check_figures_equal, image_comparison
  from matplotlib.testing._markers import needs_usetex
  import matplotlib.pyplot
label_desc: Use image node_id 8 for calling a global function with example usage: test_latex_pkg_already_loaded(preamble) without return types