docstr: Tests that a ValueError is raised if an SQL query returns two geometry columns.
docstr_tok: ["Tests","that","a","ValueError","is","raised","if","an","SQL","query","returns","two","geometry","columns","."]
code: def test_duplicate_geometry_column_fails(self, engine_postgis):
      """
      Tests that a ValueError is raised if an SQL query returns two geometry columns.
      """
      engine = engine_postgis
  
      sql = "select ST_MakePoint(0, 0) as geom, ST_MakePoint(0, 0) as geom;"
  
      with pytest.raises(ValueError):
          read_postgis(sql, engine, geom_col="geom")
  
imports: import os
  import warnings
  import pandas
  import geopandas
  from geopandas import GeoDataFrame, read_file, read_postgis
  import geopandas._compat
  from geopandas.io.sql import _get_conn, _write_postgis
  from geopandas.tests.util import create_postgis, create_spatialite, validate_boro_df
  import pytest
label_desc: Use image node_id 31 for calling the TestIO obj's underlying member method code with example usage: obj.test_duplicate_geometry_column_fails(engine_postgis) without return types