code: def test_style_to_string(geom_df):
      pytest.importorskip("lxml")
      xsl = """\
  <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
      <xsl:output method="text" indent="yes" />
      <xsl:strip-space elements="*"/>
  
      <xsl:param name="delim"><xsl:text>               </xsl:text></xsl:param>
      <xsl:template match="/data">
          <xsl:text>      shape  degrees  sides&#xa;</xsl:text>
          <xsl:apply-templates select="row"/>
      </xsl:template>
  
      <xsl:template match="row">
          <xsl:value-of select="concat(index, ' ',
                                       substring($delim, 1, string-length('triangle')
                                                 - string-length(shape) + 1),
                                       shape,
                                       substring($delim, 1, string-length(name(degrees))
                                                 - string-length(degrees) + 2),
                                       degrees,
                                       substring($delim, 1, string-length(name(sides))
                                                 - string-length(sides) + 2),
                                       sides)"/>
           <xsl:text>&#xa;</xsl:text>
      </xsl:template>
  </xsl:stylesheet>"""
  
      out_str = geom_df.to_string()
      out_xml = geom_df.to_xml(na_rep="NaN", stylesheet=xsl)
  
      assert out_xml == out_str
  
imports: from __future__ import annotations
  from io import BytesIO, StringIO
  import os
  import numpy
  import pytest
  import pandas.util._test_decorators
  from pandas import NA, DataFrame, Index
  import pandas._testing
  from pandas.io.common import get_handle
  from pandas.io.xml import read_xml
label_desc: Use image node_id 53 for calling a global function with example usage: test_style_to_string(geom_df) without return types