def METHOD_NAME(gdalenv):
    """Create an Env with a boto3 session."""
    aws_session = boto3.Session(
        aws_access_key_id="id",
        aws_secret_access_key="key",
        aws_session_token="token",
        region_name="null-island-1",
    )
    with pytest.warns(FionaDeprecationWarning):
        with fiona.env.Env(session=aws_session) as s:
            assert (
                s.session._session.get_credentials().get_frozen_credentials().access_key
                == "id"
            )
            assert (
                s.session._session.get_credentials().get_frozen_credentials().secret_key
                == "key"
            )
            assert (
                s.session._session.get_credentials().get_frozen_credentials().token
                == "token"
            )
            assert s.session._session.region_name == "null-island-1"