Server Test Python

Server Test Python

rev. 4ddf580e2646f93a77212ec640592e9f380b1bc1 (ignoring whitespace)

Files changed:

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/input.rs

@@ -739,739 +822,822 @@
  759    759   
            input: Option<
  760    760   
                impl ::std::convert::Into<
  761    761   
                    crate::constrained::MaybeConstrained<crate::model::UnknownVariantCollidingEnum>,
  762    762   
                >,
  763    763   
            >,
  764    764   
        ) -> Self {
  765    765   
            self.r#enum = input.map(|v| v.into());
  766    766   
            self
  767    767   
        }
  768    768   
        #[allow(missing_docs)] // documentation missing in model
  769         -
        pub(crate) fn set_self(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
         769  +
        pub(crate) fn set_self_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
  770    770   
            self.self_ = input.map(|v| v.into());
  771    771   
            self
  772    772   
        }
  773    773   
        #[allow(missing_docs)] // documentation missing in model
  774         -
        pub(crate) fn set_crate(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
         774  +
        pub(crate) fn set_crate_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
  775    775   
            self.crate_ = input.map(|v| v.into());
  776    776   
            self
  777    777   
        }
  778    778   
        #[allow(missing_docs)] // documentation missing in model
  779         -
        pub(crate) fn set_super(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
         779  +
        pub(crate) fn set_super_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
  780    780   
            self.super_ = input.map(|v| v.into());
  781    781   
            self
  782    782   
        }
  783    783   
        #[allow(missing_docs)] // documentation missing in model
  784         -
        pub(crate) fn set_build(
         784  +
        pub(crate) fn set_build_value(
  785    785   
            mut self,
  786    786   
            input: Option<impl ::std::convert::Into<::std::string::String>>,
  787    787   
        ) -> Self {
  788    788   
            self.build_value = input.map(|v| v.into());
  789    789   
            self
  790    790   
        }
  791    791   
        #[allow(missing_docs)] // documentation missing in model
  792         -
        pub(crate) fn set_default(
         792  +
        pub(crate) fn set_default_value(
  793    793   
            mut self,
  794    794   
            input: Option<impl ::std::convert::Into<::std::string::String>>,
  795    795   
        ) -> Self {
  796    796   
            self.default_value = input.map(|v| v.into());
  797    797   
            self
  798    798   
        }
  799    799   
        #[allow(missing_docs)] // documentation missing in model
  800    800   
        pub(crate) fn set_send(
  801    801   
            mut self,
  802    802   
            input: Option<impl ::std::convert::Into<::std::string::String>>,
@@ -1004,1004 +1087,1087 @@
 1024   1024   
            input: Option<
 1025   1025   
                impl ::std::convert::Into<
 1026   1026   
                    crate::constrained::MaybeConstrained<crate::model::UnknownVariantCollidingEnum>,
 1027   1027   
                >,
 1028   1028   
            >,
 1029   1029   
        ) -> Self {
 1030   1030   
            self.r#enum = input.map(|v| v.into());
 1031   1031   
            self
 1032   1032   
        }
 1033   1033   
        #[allow(missing_docs)] // documentation missing in model
 1034         -
        pub(crate) fn set_self(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
        1034  +
        pub(crate) fn set_self_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
 1035   1035   
            self.self_ = input.map(|v| v.into());
 1036   1036   
            self
 1037   1037   
        }
 1038   1038   
        #[allow(missing_docs)] // documentation missing in model
 1039         -
        pub(crate) fn set_crate(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
        1039  +
        pub(crate) fn set_crate_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
 1040   1040   
            self.crate_ = input.map(|v| v.into());
 1041   1041   
            self
 1042   1042   
        }
 1043   1043   
        #[allow(missing_docs)] // documentation missing in model
 1044         -
        pub(crate) fn set_super(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
        1044  +
        pub(crate) fn set_super_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
 1045   1045   
            self.super_ = input.map(|v| v.into());
 1046   1046   
            self
 1047   1047   
        }
 1048   1048   
        #[allow(missing_docs)] // documentation missing in model
 1049         -
        pub(crate) fn set_build(
        1049  +
        pub(crate) fn set_build_value(
 1050   1050   
            mut self,
 1051   1051   
            input: Option<impl ::std::convert::Into<::std::string::String>>,
 1052   1052   
        ) -> Self {
 1053   1053   
            self.build_value = input.map(|v| v.into());
 1054   1054   
            self
 1055   1055   
        }
 1056   1056   
        #[allow(missing_docs)] // documentation missing in model
 1057         -
        pub(crate) fn set_default(
        1057  +
        pub(crate) fn set_default_value(
 1058   1058   
            mut self,
 1059   1059   
            input: Option<impl ::std::convert::Into<::std::string::String>>,
 1060   1060   
        ) -> Self {
 1061   1061   
            self.default_value = input.map(|v| v.into());
 1062   1062   
            self
 1063   1063   
        }
 1064   1064   
        #[allow(missing_docs)] // documentation missing in model
 1065   1065   
        pub(crate) fn set_send(
 1066   1066   
            mut self,
 1067   1067   
            input: Option<impl ::std::convert::Into<::std::string::String>>,
@@ -1522,1522 +1605,1605 @@
 1542   1542   
            input: Option<
 1543   1543   
                impl ::std::convert::Into<
 1544   1544   
                    crate::constrained::MaybeConstrained<crate::model::UnknownVariantCollidingEnum>,
 1545   1545   
                >,
 1546   1546   
            >,
 1547   1547   
        ) -> Self {
 1548   1548   
            self.r#enum = input.map(|v| v.into());
 1549   1549   
            self
 1550   1550   
        }
 1551   1551   
        #[allow(missing_docs)] // documentation missing in model
 1552         -
        pub(crate) fn set_self(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
        1552  +
        pub(crate) fn set_self_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
 1553   1553   
            self.self_ = input.map(|v| v.into());
 1554   1554   
            self
 1555   1555   
        }
 1556   1556   
        #[allow(missing_docs)] // documentation missing in model
 1557         -
        pub(crate) fn set_crate(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
        1557  +
        pub(crate) fn set_crate_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
 1558   1558   
            self.crate_ = input.map(|v| v.into());
 1559   1559   
            self
 1560   1560   
        }
 1561   1561   
        #[allow(missing_docs)] // documentation missing in model
 1562         -
        pub(crate) fn set_super(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
        1562  +
        pub(crate) fn set_super_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
 1563   1563   
            self.super_ = input.map(|v| v.into());
 1564   1564   
            self
 1565   1565   
        }
 1566   1566   
        #[allow(missing_docs)] // documentation missing in model
 1567         -
        pub(crate) fn set_build(
        1567  +
        pub(crate) fn set_build_value(
 1568   1568   
            mut self,
 1569   1569   
            input: Option<impl ::std::convert::Into<::std::string::String>>,
 1570   1570   
        ) -> Self {
 1571   1571   
            self.build_value = input.map(|v| v.into());
 1572   1572   
            self
 1573   1573   
        }
 1574   1574   
        #[allow(missing_docs)] // documentation missing in model
 1575         -
        pub(crate) fn set_default(
        1575  +
        pub(crate) fn set_default_value(
 1576   1576   
            mut self,
 1577   1577   
            input: Option<impl ::std::convert::Into<::std::string::String>>,
 1578   1578   
        ) -> Self {
 1579   1579   
            self.default_value = input.map(|v| v.into());
 1580   1580   
            self
 1581   1581   
        }
 1582   1582   
        #[allow(missing_docs)] // documentation missing in model
 1583   1583   
        pub(crate) fn set_send(
 1584   1584   
            mut self,
 1585   1585   
            input: Option<impl ::std::convert::Into<::std::string::String>>,

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/protocol_serde/shape_match.rs

@@ -127,127 +217,217 @@
  147    147   
                    "enum" => {
  148    148   
                        builder = builder.set_enum(
  149    149   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(
  150    150   
                                tokens.next(),
  151    151   
                            )?
  152    152   
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  153    153   
                            .transpose()?,
  154    154   
                        );
  155    155   
                    }
  156    156   
                    "self" => {
  157         -
                        builder = builder.set_self(
         157  +
                        builder = builder.set_self_(
  158    158   
                            ::aws_smithy_json::deserialize::token::expect_bool_or_null(
  159    159   
                                tokens.next(),
  160    160   
                            )?,
  161    161   
                        );
  162    162   
                    }
  163    163   
                    "crate" => {
  164         -
                        builder = builder.set_crate(
         164  +
                        builder = builder.set_crate_(
  165    165   
                            ::aws_smithy_json::deserialize::token::expect_bool_or_null(
  166    166   
                                tokens.next(),
  167    167   
                            )?,
  168    168   
                        );
  169    169   
                    }
  170    170   
                    "super" => {
  171         -
                        builder = builder.set_super(
         171  +
                        builder = builder.set_super_(
  172    172   
                            ::aws_smithy_json::deserialize::token::expect_bool_or_null(
  173    173   
                                tokens.next(),
  174    174   
                            )?,
  175    175   
                        );
  176    176   
                    }
  177    177   
                    "build" => {
  178         -
                        builder = builder.set_build(
         178  +
                        builder = builder.set_build_value(
  179    179   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(
  180    180   
                                tokens.next(),
  181    181   
                            )?
  182    182   
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  183    183   
                            .transpose()?,
  184    184   
                        );
  185    185   
                    }
  186    186   
                    "default" => {
  187         -
                        builder = builder.set_default(
         187  +
                        builder = builder.set_default_value(
  188    188   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(
  189    189   
                                tokens.next(),
  190    190   
                            )?
  191    191   
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  192    192   
                            .transpose()?,
  193    193   
                        );
  194    194   
                    }
  195    195   
                    "send" => {
  196    196   
                        builder = builder.set_send(
  197    197   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/protocol_serde/shape_reserved_words_as_members.rs

@@ -127,127 +217,217 @@
  147    147   
                    "enum" => {
  148    148   
                        builder = builder.set_enum(
  149    149   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(
  150    150   
                                tokens.next(),
  151    151   
                            )?
  152    152   
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  153    153   
                            .transpose()?,
  154    154   
                        );
  155    155   
                    }
  156    156   
                    "self" => {
  157         -
                        builder = builder.set_self(
         157  +
                        builder = builder.set_self_(
  158    158   
                            ::aws_smithy_json::deserialize::token::expect_bool_or_null(
  159    159   
                                tokens.next(),
  160    160   
                            )?,
  161    161   
                        );
  162    162   
                    }
  163    163   
                    "crate" => {
  164         -
                        builder = builder.set_crate(
         164  +
                        builder = builder.set_crate_(
  165    165   
                            ::aws_smithy_json::deserialize::token::expect_bool_or_null(
  166    166   
                                tokens.next(),
  167    167   
                            )?,
  168    168   
                        );
  169    169   
                    }
  170    170   
                    "super" => {
  171         -
                        builder = builder.set_super(
         171  +
                        builder = builder.set_super_(
  172    172   
                            ::aws_smithy_json::deserialize::token::expect_bool_or_null(
  173    173   
                                tokens.next(),
  174    174   
                            )?,
  175    175   
                        );
  176    176   
                    }
  177    177   
                    "build" => {
  178         -
                        builder = builder.set_build(
         178  +
                        builder = builder.set_build_value(
  179    179   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(
  180    180   
                                tokens.next(),
  181    181   
                            )?
  182    182   
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  183    183   
                            .transpose()?,
  184    184   
                        );
  185    185   
                    }
  186    186   
                    "default" => {
  187         -
                        builder = builder.set_default(
         187  +
                        builder = builder.set_default_value(
  188    188   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(
  189    189   
                                tokens.next(),
  190    190   
                            )?
  191    191   
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  192    192   
                            .transpose()?,
  193    193   
                        );
  194    194   
                    }
  195    195   
                    "send" => {
  196    196   
                        builder = builder.set_send(
  197    197   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(

tmp-codegen-diff/codegen-server-test-python/naming_test_ops/rust-server-codegen-python/src/protocol_serde/shape_rpc_echo.rs

@@ -127,127 +217,217 @@
  147    147   
                    "enum" => {
  148    148   
                        builder = builder.set_enum(
  149    149   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(
  150    150   
                                tokens.next(),
  151    151   
                            )?
  152    152   
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  153    153   
                            .transpose()?,
  154    154   
                        );
  155    155   
                    }
  156    156   
                    "self" => {
  157         -
                        builder = builder.set_self(
         157  +
                        builder = builder.set_self_(
  158    158   
                            ::aws_smithy_json::deserialize::token::expect_bool_or_null(
  159    159   
                                tokens.next(),
  160    160   
                            )?,
  161    161   
                        );
  162    162   
                    }
  163    163   
                    "crate" => {
  164         -
                        builder = builder.set_crate(
         164  +
                        builder = builder.set_crate_(
  165    165   
                            ::aws_smithy_json::deserialize::token::expect_bool_or_null(
  166    166   
                                tokens.next(),
  167    167   
                            )?,
  168    168   
                        );
  169    169   
                    }
  170    170   
                    "super" => {
  171         -
                        builder = builder.set_super(
         171  +
                        builder = builder.set_super_(
  172    172   
                            ::aws_smithy_json::deserialize::token::expect_bool_or_null(
  173    173   
                                tokens.next(),
  174    174   
                            )?,
  175    175   
                        );
  176    176   
                    }
  177    177   
                    "build" => {
  178         -
                        builder = builder.set_build(
         178  +
                        builder = builder.set_build_value(
  179    179   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(
  180    180   
                                tokens.next(),
  181    181   
                            )?
  182    182   
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  183    183   
                            .transpose()?,
  184    184   
                        );
  185    185   
                    }
  186    186   
                    "default" => {
  187         -
                        builder = builder.set_default(
         187  +
                        builder = builder.set_default_value(
  188    188   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(
  189    189   
                                tokens.next(),
  190    190   
                            )?
  191    191   
                            .map(|s| s.to_unescaped().map(|u| u.into_owned()))
  192    192   
                            .transpose()?,
  193    193   
                        );
  194    194   
                    }
  195    195   
                    "send" => {
  196    196   
                        builder = builder.set_send(
  197    197   
                            ::aws_smithy_json::deserialize::token::expect_string_or_null(