Client Test

Client Test

rev. 27102829f69b2cfe3a9ca9e69ae64d1ea40f9865 (ignoring whitespace)

Files changed:

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/http_request_with_greedy_label_in_path.rs

@@ -223,223 +284,286 @@
  243    243   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  244    244   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  245    245   
        let _input = context
  246    246   
            .input()
  247    247   
            .downcast_ref::<HttpRequestWithGreedyLabelInPathInput>()
  248    248   
            .ok_or("failed to downcast to HttpRequestWithGreedyLabelInPathInput")?;
  249    249   
  250    250   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  251    251   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  252    252   
        })?;
         253  +
  253    254   
        cfg.interceptor_state()
  254    255   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         256  +
  255    257   
        ::std::result::Result::Ok(())
  256    258   
    }
  257    259   
}
  258    260   
  259    261   
// The get_* functions below are generated from JMESPath expressions in the
  260    262   
// operationContextParams trait. They target the operation's input shape.
  261    263   
  262    264   
#[allow(unreachable_code, unused_variables)]
  263    265   
#[cfg(test)]
  264    266   
mod http_request_with_greedy_label_in_path_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/http_request_with_labels.rs

@@ -302,302 +363,365 @@
  322    322   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  323    323   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  324    324   
        let _input = context
  325    325   
            .input()
  326    326   
            .downcast_ref::<HttpRequestWithLabelsInput>()
  327    327   
            .ok_or("failed to downcast to HttpRequestWithLabelsInput")?;
  328    328   
  329    329   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  330    330   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  331    331   
        })?;
         332  +
  332    333   
        cfg.interceptor_state()
  333    334   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         335  +
  334    336   
        ::std::result::Result::Ok(())
  335    337   
    }
  336    338   
}
  337    339   
  338    340   
// The get_* functions below are generated from JMESPath expressions in the
  339    341   
// operationContextParams trait. They target the operation's input shape.
  340    342   
  341    343   
#[allow(unreachable_code, unused_variables)]
  342    344   
#[cfg(test)]
  343    345   
mod http_request_with_labels_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/http_request_with_labels_and_timestamp_format.rs

@@ -277,277 +338,340 @@
  297    297   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  298    298   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  299    299   
        let _input = context
  300    300   
            .input()
  301    301   
            .downcast_ref::<HttpRequestWithLabelsAndTimestampFormatInput>()
  302    302   
            .ok_or("failed to downcast to HttpRequestWithLabelsAndTimestampFormatInput")?;
  303    303   
  304    304   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  305    305   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  306    306   
        })?;
         307  +
  307    308   
        cfg.interceptor_state()
  308    309   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         310  +
  309    311   
        ::std::result::Result::Ok(())
  310    312   
    }
  311    313   
}
  312    314   
  313    315   
// The get_* functions below are generated from JMESPath expressions in the
  314    316   
// operationContextParams trait. They target the operation's input shape.
  315    317   
  316    318   
#[allow(unreachable_code, unused_variables)]
  317    319   
#[cfg(test)]
  318    320   
mod http_request_with_labels_and_timestamp_format_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/http_response_code.rs

@@ -196,196 +257,259 @@
  216    216   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  217    217   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  218    218   
        let _input = context
  219    219   
            .input()
  220    220   
            .downcast_ref::<HttpResponseCodeInput>()
  221    221   
            .ok_or("failed to downcast to HttpResponseCodeInput")?;
  222    222   
  223    223   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  224    224   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  225    225   
        })?;
         226  +
  226    227   
        cfg.interceptor_state()
  227    228   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         229  +
  228    230   
        ::std::result::Result::Ok(())
  229    231   
    }
  230    232   
}
  231    233   
  232    234   
// The get_* functions below are generated from JMESPath expressions in the
  233    235   
// operationContextParams trait. They target the operation's input shape.
  234    236   
  235    237   
#[allow(unreachable_code, unused_variables)]
  236    238   
#[cfg(test)]
  237    239   
mod http_response_code_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/http_string_payload.rs

@@ -202,202 +263,265 @@
  222    222   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  223    223   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  224    224   
        let _input = context
  225    225   
            .input()
  226    226   
            .downcast_ref::<HttpStringPayloadInput>()
  227    227   
            .ok_or("failed to downcast to HttpStringPayloadInput")?;
  228    228   
  229    229   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  230    230   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  231    231   
        })?;
         232  +
  232    233   
        cfg.interceptor_state()
  233    234   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         235  +
  234    236   
        ::std::result::Result::Ok(())
  235    237   
    }
  236    238   
}
  237    239   
  238    240   
// The get_* functions below are generated from JMESPath expressions in the
  239    241   
// operationContextParams trait. They target the operation's input shape.
  240    242   
  241    243   
#[allow(unreachable_code, unused_variables)]
  242    244   
#[cfg(test)]
  243    245   
mod http_string_payload_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/ignore_query_params_in_response.rs

@@ -196,196 +257,259 @@
  216    216   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  217    217   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  218    218   
        let _input = context
  219    219   
            .input()
  220    220   
            .downcast_ref::<IgnoreQueryParamsInResponseInput>()
  221    221   
            .ok_or("failed to downcast to IgnoreQueryParamsInResponseInput")?;
  222    222   
  223    223   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  224    224   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  225    225   
        })?;
         226  +
  226    227   
        cfg.interceptor_state()
  227    228   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         229  +
  228    230   
        ::std::result::Result::Ok(())
  229    231   
    }
  230    232   
}
  231    233   
  232    234   
// The get_* functions below are generated from JMESPath expressions in the
  233    235   
// operationContextParams trait. They target the operation's input shape.
  234    236   
  235    237   
#[allow(unreachable_code, unused_variables)]
  236    238   
#[cfg(test)]
  237    239   
mod ignore_query_params_in_response_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/input_and_output_with_headers.rs

@@ -197,197 +258,260 @@
  217    217   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  218    218   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  219    219   
        let _input = context
  220    220   
            .input()
  221    221   
            .downcast_ref::<InputAndOutputWithHeadersInput>()
  222    222   
            .ok_or("failed to downcast to InputAndOutputWithHeadersInput")?;
  223    223   
  224    224   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  225    225   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  226    226   
        })?;
         227  +
  227    228   
        cfg.interceptor_state()
  228    229   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         230  +
  229    231   
        ::std::result::Result::Ok(())
  230    232   
    }
  231    233   
}
  232    234   
  233    235   
// The get_* functions below are generated from JMESPath expressions in the
  234    236   
// operationContextParams trait. They target the operation's input shape.
  235    237   
  236    238   
#[allow(unreachable_code, unused_variables)]
  237    239   
#[cfg(test)]
  238    240   
mod input_and_output_with_headers_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/nested_xml_map_with_xml_name.rs

@@ -202,202 +263,265 @@
  222    222   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  223    223   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  224    224   
        let _input = context
  225    225   
            .input()
  226    226   
            .downcast_ref::<NestedXmlMapWithXmlNameInput>()
  227    227   
            .ok_or("failed to downcast to NestedXmlMapWithXmlNameInput")?;
  228    228   
  229    229   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  230    230   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  231    231   
        })?;
         232  +
  232    233   
        cfg.interceptor_state()
  233    234   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         235  +
  234    236   
        ::std::result::Result::Ok(())
  235    237   
    }
  236    238   
}
  237    239   
  238    240   
// The get_* functions below are generated from JMESPath expressions in the
  239    241   
// operationContextParams trait. They target the operation's input shape.
  240    242   
  241    243   
#[allow(unreachable_code, unused_variables)]
  242    244   
#[cfg(test)]
  243    245   
mod nested_xml_map_with_xml_name_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/nested_xml_maps.rs

@@ -194,194 +255,257 @@
  214    214   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  215    215   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  216    216   
        let _input = context
  217    217   
            .input()
  218    218   
            .downcast_ref::<NestedXmlMapsInput>()
  219    219   
            .ok_or("failed to downcast to NestedXmlMapsInput")?;
  220    220   
  221    221   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  222    222   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  223    223   
        })?;
         224  +
  224    225   
        cfg.interceptor_state()
  225    226   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         227  +
  226    228   
        ::std::result::Result::Ok(())
  227    229   
    }
  228    230   
}
  229    231   
  230    232   
// The get_* functions below are generated from JMESPath expressions in the
  231    233   
// operationContextParams trait. They target the operation's input shape.
  232    234   
  233    235   
#[allow(unreachable_code, unused_variables)]
  234    236   
#[cfg(test)]
  235    237   
mod nested_xml_maps_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/no_input_and_no_output.rs

@@ -196,196 +257,259 @@
  216    216   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  217    217   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  218    218   
        let _input = context
  219    219   
            .input()
  220    220   
            .downcast_ref::<NoInputAndNoOutputInput>()
  221    221   
            .ok_or("failed to downcast to NoInputAndNoOutputInput")?;
  222    222   
  223    223   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  224    224   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  225    225   
        })?;
         226  +
  226    227   
        cfg.interceptor_state()
  227    228   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         229  +
  228    230   
        ::std::result::Result::Ok(())
  229    231   
    }
  230    232   
}
  231    233   
  232    234   
// The get_* functions below are generated from JMESPath expressions in the
  233    235   
// operationContextParams trait. They target the operation's input shape.
  234    236   
  235    237   
#[allow(unreachable_code, unused_variables)]
  236    238   
#[cfg(test)]
  237    239   
mod no_input_and_no_output_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/no_input_and_output.rs

@@ -196,196 +257,259 @@
  216    216   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  217    217   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  218    218   
        let _input = context
  219    219   
            .input()
  220    220   
            .downcast_ref::<NoInputAndOutputInput>()
  221    221   
            .ok_or("failed to downcast to NoInputAndOutputInput")?;
  222    222   
  223    223   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  224    224   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  225    225   
        })?;
         226  +
  226    227   
        cfg.interceptor_state()
  227    228   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         229  +
  228    230   
        ::std::result::Result::Ok(())
  229    231   
    }
  230    232   
}
  231    233   
  232    234   
// The get_* functions below are generated from JMESPath expressions in the
  233    235   
// operationContextParams trait. They target the operation's input shape.
  234    236   
  235    237   
#[allow(unreachable_code, unused_variables)]
  236    238   
#[cfg(test)]
  237    239   
mod no_input_and_output_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/null_and_empty_headers_client.rs

@@ -197,197 +258,260 @@
  217    217   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  218    218   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  219    219   
        let _input = context
  220    220   
            .input()
  221    221   
            .downcast_ref::<NullAndEmptyHeadersClientInput>()
  222    222   
            .ok_or("failed to downcast to NullAndEmptyHeadersClientInput")?;
  223    223   
  224    224   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  225    225   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  226    226   
        })?;
         227  +
  227    228   
        cfg.interceptor_state()
  228    229   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         230  +
  229    231   
        ::std::result::Result::Ok(())
  230    232   
    }
  231    233   
}
  232    234   
  233    235   
// The get_* functions below are generated from JMESPath expressions in the
  234    236   
// operationContextParams trait. They target the operation's input shape.
  235    237   
  236    238   
#[allow(unreachable_code, unused_variables)]
  237    239   
#[cfg(test)]
  238    240   
mod null_and_empty_headers_client_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/null_and_empty_headers_server.rs

@@ -197,197 +258,260 @@
  217    217   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  218    218   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  219    219   
        let _input = context
  220    220   
            .input()
  221    221   
            .downcast_ref::<NullAndEmptyHeadersServerInput>()
  222    222   
            .ok_or("failed to downcast to NullAndEmptyHeadersServerInput")?;
  223    223   
  224    224   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  225    225   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  226    226   
        })?;
         227  +
  227    228   
        cfg.interceptor_state()
  228    229   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         230  +
  229    231   
        ::std::result::Result::Ok(())
  230    232   
    }
  231    233   
}
  232    234   
  233    235   
// The get_* functions below are generated from JMESPath expressions in the
  234    236   
// operationContextParams trait. They target the operation's input shape.
  235    237   
  236    238   
/// Error type for the `NullAndEmptyHeadersServerError` operation.
  237    239   
#[non_exhaustive]
  238    240   
#[derive(::std::fmt::Debug)]

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/omits_null_serializes_empty_string.rs

@@ -216,216 +277,279 @@
  236    236   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  237    237   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  238    238   
        let _input = context
  239    239   
            .input()
  240    240   
            .downcast_ref::<OmitsNullSerializesEmptyStringInput>()
  241    241   
            .ok_or("failed to downcast to OmitsNullSerializesEmptyStringInput")?;
  242    242   
  243    243   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  244    244   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  245    245   
        })?;
         246  +
  246    247   
        cfg.interceptor_state()
  247    248   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         249  +
  248    250   
        ::std::result::Result::Ok(())
  249    251   
    }
  250    252   
}
  251    253   
  252    254   
// The get_* functions below are generated from JMESPath expressions in the
  253    255   
// operationContextParams trait. They target the operation's input shape.
  254    256   
  255    257   
#[allow(unreachable_code, unused_variables)]
  256    258   
#[cfg(test)]
  257    259   
mod omits_null_serializes_empty_string_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/put_with_content_encoding.rs

@@ -203,203 +264,266 @@
  223    223   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  224    224   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  225    225   
        let _input = context
  226    226   
            .input()
  227    227   
            .downcast_ref::<PutWithContentEncodingInput>()
  228    228   
            .ok_or("failed to downcast to PutWithContentEncodingInput")?;
  229    229   
  230    230   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  231    231   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  232    232   
        })?;
         233  +
  233    234   
        cfg.interceptor_state()
  234    235   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         236  +
  235    237   
        ::std::result::Result::Ok(())
  236    238   
    }
  237    239   
}
  238    240   
  239    241   
// The get_* functions below are generated from JMESPath expressions in the
  240    242   
// operationContextParams trait. They target the operation's input shape.
  241    243   
  242    244   
#[allow(unreachable_code, unused_variables)]
  243    245   
#[cfg(test)]
  244    246   
mod put_with_content_encoding_test {

tmp-codegen-diff/codegen-client-test/rest_xml/rust-client-codegen/src/operation/query_idempotency_token_auto_fill.rs

@@ -217,217 +278,280 @@
  237    237   
        cfg: &mut ::aws_smithy_types::config_bag::ConfigBag,
  238    238   
    ) -> ::std::result::Result<(), ::aws_smithy_runtime_api::box_error::BoxError> {
  239    239   
        let _input = context
  240    240   
            .input()
  241    241   
            .downcast_ref::<QueryIdempotencyTokenAutoFillInput>()
  242    242   
            .ok_or("failed to downcast to QueryIdempotencyTokenAutoFillInput")?;
  243    243   
  244    244   
        let params = crate::config::endpoint::Params::builder().build().map_err(|err| {
  245    245   
            ::aws_smithy_runtime_api::client::interceptors::error::ContextAttachedError::new("endpoint params could not be built", err)
  246    246   
        })?;
         247  +
  247    248   
        cfg.interceptor_state()
  248    249   
            .store_put(::aws_smithy_runtime_api::client::endpoint::EndpointResolverParams::new(params));
         250  +
  249    251   
        ::std::result::Result::Ok(())
  250    252   
    }
  251    253   
}
  252    254   
  253    255   
// The get_* functions below are generated from JMESPath expressions in the
  254    256   
// operationContextParams trait. They target the operation's input shape.
  255    257   
  256    258   
#[allow(unreachable_code, unused_variables)]
  257    259   
#[cfg(test)]
  258    260   
mod query_idempotency_token_auto_fill_test {