code: def test_crs_should_be_set(path_rgb_byte_tif, tmpdir, complex):
      """When ``dst_height``, ``dst_width``, and ``dst_transform`` are set
      :py:class:`rasterio.warp.WarpedVRT` calls ``GDALCreateWarpedVRT()``,
      which requires the caller to then set a projection with
      ``GDALSetProjection()``.
  
      Permalink to ``GDALCreateWarpedVRT()`` call:
  
          https://github.com/rasterio/rasterio/blob/1f759e5f67628f163ea2550d8926b91545245712/rasterio/_warp.pyx#L753
  
      """
  
      vrt_path = str(tmpdir.join("test_crs_should_be_set.vrt"))
  
      with rasterio.open(path_rgb_byte_tif) as src:
          dst_crs = "EPSG:4326"
          dst_height = dst_width = 10
          dst_bounds = transform_bounds(src.crs, dst_crs, *src.bounds)
  
          # Destination transform
          left, bottom, right, top = dst_bounds
          xres = (right - left) / dst_width
          yres = (top - bottom) / dst_height
          dst_transform = affine.Affine(
              xres, 0.0, left, 0.0, -yres, top
          )
  
          # The 'complex' test case hits the affected code path
          vrt_options = {"dst_crs": dst_crs}
          if complex:
              vrt_options.update(
                  crs=dst_crs,
                  height=dst_height,
                  width=dst_width,
                  transform=dst_transform,
                  resampling=Resampling.nearest,
              )
  
          with WarpedVRT(src, **vrt_options) as vrt:
              rio_shutil.copy(vrt, vrt_path, driver="VRT")
          with rasterio.open(vrt_path) as src:
              assert src.crs
  
imports: from __future__ import division
  import logging
  import shutil
  import affine
  import numpy
  import pytest
  import rasterio
  from rasterio.control import GroundControlPoint
  from rasterio.crs import CRS
  from rasterio.enums import Resampling, MaskFlags
  from rasterio.errors import WarpOptionsError
  from rasterio.io import MemoryFile
  from rasterio import shutil
  from rasterio.vrt import WarpedVRT
  from rasterio.warp import transform_bounds
  from rasterio.windows import Window
  from .conftest import gdal_version, credentials
label_desc: Use image node_id 16 for calling a global function with example usage: test_crs_should_be_set(path_rgb_byte_tif, tmpdir, complex) without return types