@@ -3032,55 +3032,55 @@ TEST_F(xapi, compression_algorithms)
3032
3032
std::chrono::time_point<std::chrono::system_clock> start_time
3033
3033
= std::chrono::system_clock::now ();
3034
3034
3035
- tmp = std::string ( uri) + " compression-algorithms=" + d.name ;
3035
+ tmp = uri + " compression-algorithms=" + d.name ;
3036
3036
check_compress_alg (
3037
3037
mysqlx_get_session_from_url (
3038
3038
tmp.c_str (),
3039
3039
&error),
3040
3040
d.expected , __LINE__);
3041
3041
3042
- tmp = std::string ( uri) + " compression-algorithms=" + d.alias ;
3042
+ tmp = uri + " compression-algorithms=" + d.alias ;
3043
3043
check_compress_alg (
3044
3044
mysqlx_get_session_from_url (
3045
3045
tmp.c_str (),
3046
3046
&error),
3047
3047
d.expected , __LINE__);
3048
3048
3049
- tmp = std::string ( uri) + " compression-algorithms=[" + d.name + " ]" ;
3049
+ tmp = uri + " compression-algorithms=[" + d.name + " ]" ;
3050
3050
check_compress_alg (
3051
3051
mysqlx_get_session_from_url (
3052
3052
tmp.c_str (),
3053
3053
&error),
3054
3054
d.expected , __LINE__);
3055
3055
3056
- tmp = std::string ( uri) + " compression-algorithms=[" + d.name + " ," + d.second + " ," + d.name + " ]" ;
3056
+ tmp = uri + " compression-algorithms=[" + d.name + " ," + d.second + " ," + d.name + " ]" ;
3057
3057
check_compress_alg (
3058
3058
mysqlx_get_session_from_url (
3059
3059
tmp.c_str (),
3060
3060
&error),
3061
3061
d.expected , __LINE__);
3062
3062
3063
- tmp = std::string ( uri) + " compression-algorithms=[" + d.name + " ," + d.second + " ," + d.third + " ]" ;
3063
+ tmp = uri + " compression-algorithms=[" + d.name + " ," + d.second + " ," + d.third + " ]" ;
3064
3064
check_compress_alg (
3065
3065
mysqlx_get_session_from_url (
3066
3066
tmp.c_str (),
3067
3067
&error), d.expected , __LINE__);
3068
3068
3069
- tmp = std::string ( uri) + " compression-algorithms=[" + d.alias + " ]" ;
3069
+ tmp = uri + " compression-algorithms=[" + d.alias + " ]" ;
3070
3070
check_compress_alg (
3071
3071
mysqlx_get_session_from_url (
3072
3072
tmp.c_str (),
3073
3073
&error),
3074
3074
d.expected , __LINE__);
3075
3075
3076
- tmp = std::string ( uri) + " compression-algorithms=[" + d.alias + " ," + d.second + " ," + d.name + " ]" ;
3076
+ tmp = uri + " compression-algorithms=[" + d.alias + " ," + d.second + " ," + d.name + " ]" ;
3077
3077
check_compress_alg (
3078
3078
mysqlx_get_session_from_url (
3079
3079
tmp.c_str (),
3080
3080
&error),
3081
3081
d.expected , __LINE__);
3082
3082
3083
- tmp = std::string ( uri) + " compression-algorithms=[MyALGORITHM," + d.name + " ]" ;
3083
+ tmp = uri + " compression-algorithms=[MyALGORITHM," + d.name + " ]" ;
3084
3084
check_compress_alg (
3085
3085
mysqlx_get_session_from_url (
3086
3086
tmp.c_str (),
@@ -3089,49 +3089,49 @@ TEST_F(xapi, compression_algorithms)
3089
3089
3090
3090
// Even if a valid algorithm is selected, if compression is disabled,
3091
3091
// no compression should be used
3092
- tmp = std::string ( uri) + " Compression=Disabled&Compression-Algorithms=" + d.name ;
3092
+ tmp = uri + " Compression=Disabled&Compression-Algorithms=" + d.name ;
3093
3093
check_compress_alg (
3094
3094
mysqlx_get_session_from_url (
3095
3095
tmp.c_str (),
3096
3096
&error),
3097
3097
std::string (), __LINE__);
3098
3098
3099
- tmp = std::string ( uri) + " Compression=Disabled&Compression-Algorithms=" + d.alias ;
3099
+ tmp = uri + " Compression=Disabled&Compression-Algorithms=" + d.alias ;
3100
3100
check_compress_alg (
3101
3101
mysqlx_get_session_from_url (
3102
3102
tmp.c_str (),
3103
3103
&error),
3104
3104
std::string (), __LINE__);
3105
3105
3106
- tmp = std::string ( uri) + " Compression=Disabled&Compression-Algorithms=[" + d.name + " ]" ;
3106
+ tmp = uri + " Compression=Disabled&Compression-Algorithms=[" + d.name + " ]" ;
3107
3107
check_compress_alg (
3108
3108
mysqlx_get_session_from_url (
3109
3109
tmp.c_str (),
3110
3110
&error),
3111
3111
std::string (), __LINE__);
3112
3112
3113
- tmp = std::string ( uri) + " Compression=Disabled&Compression-Algorithms=[" + d.name + " ," + d.name + " ]" ;
3113
+ tmp = uri + " Compression=Disabled&Compression-Algorithms=[" + d.name + " ," + d.name + " ]" ;
3114
3114
check_compress_alg (
3115
3115
mysqlx_get_session_from_url (
3116
3116
tmp.c_str (),
3117
3117
&error),
3118
3118
std::string (), __LINE__);
3119
3119
3120
- tmp = std::string ( uri) + " Compression=Disabled&Compression-Algorithms=[" + d.alias + " ]" ;
3120
+ tmp = uri + " Compression=Disabled&Compression-Algorithms=[" + d.alias + " ]" ;
3121
3121
check_compress_alg (
3122
3122
mysqlx_get_session_from_url (
3123
3123
tmp.c_str (),
3124
3124
&error),
3125
3125
std::string (), __LINE__);
3126
3126
3127
- tmp = std::string ( uri) + " Compression=Disabled&Compression-Algorithms=[" + d.alias + " ," + d.name + " ]" ;
3127
+ tmp = uri + " Compression=Disabled&Compression-Algorithms=[" + d.alias + " ," + d.name + " ]" ;
3128
3128
check_compress_alg (
3129
3129
mysqlx_get_session_from_url (
3130
3130
tmp.c_str (),
3131
3131
&error),
3132
3132
std::string (), __LINE__);
3133
3133
3134
- tmp = std::string ( uri) + " Compression=Disabled&Compression-Algorithms=[MyALGORITHM," + d.name + " ]" ;
3134
+ tmp = uri + " Compression=Disabled&Compression-Algorithms=[MyALGORITHM," + d.name + " ]" ;
3135
3135
check_compress_alg (
3136
3136
mysqlx_get_session_from_url (
3137
3137
tmp.c_str (),
@@ -3140,27 +3140,27 @@ TEST_F(xapi, compression_algorithms)
3140
3140
3141
3141
// In this cases, no algorithm should be used, since algorithm value
3142
3142
// is empty or not valid
3143
- tmp = std::string ( uri) + " compression-algorithms=" ;
3143
+ tmp = uri + " compression-algorithms=" ;
3144
3144
check_compress_alg (mysqlx_get_session_from_url (tmp.c_str (), &error), " " , __LINE__);
3145
- tmp = std::string ( uri) + " compression-algorithms=[]" ;
3145
+ tmp = uri + " compression-algorithms=[]" ;
3146
3146
check_compress_alg (mysqlx_get_session_from_url (tmp.c_str (), &error), " " , __LINE__);
3147
- tmp = std::string ( uri) + " compression-algorithms=BAD_Algorithm" ;
3147
+ tmp = uri + " compression-algorithms=BAD_Algorithm" ;
3148
3148
check_compress_alg (mysqlx_get_session_from_url (tmp.c_str (), &error), " " , __LINE__);
3149
- tmp = std::string ( uri) + " compression-algorithms=[BAD_Algorithm]" ;
3149
+ tmp = uri + " compression-algorithms=[BAD_Algorithm]" ;
3150
3150
check_compress_alg (mysqlx_get_session_from_url (tmp.c_str (), &error), " " , __LINE__);
3151
- tmp = std::string ( uri) + " compression-algorithms=[BAD_Algorithm,BAD_Algorithm]" ;
3151
+ tmp = uri + " compression-algorithms=[BAD_Algorithm,BAD_Algorithm]" ;
3152
3152
check_compress_alg (mysqlx_get_session_from_url (tmp.c_str (), &error), " " , __LINE__);
3153
3153
3154
3154
// If compression=REQUIRED and no valid algorithm selected, no session should be created
3155
- tmp = std::string ( uri) + " compression=required&compression-algorithms=" ;
3155
+ tmp = uri + " compression=required&compression-algorithms=" ;
3156
3156
EXPECT_EQ (nullptr , mysqlx_get_session_from_url (tmp.c_str (), &error));
3157
- tmp = std::string ( uri) + " compression=required&compression-algorithms=[]" ;
3157
+ tmp = uri + " compression=required&compression-algorithms=[]" ;
3158
3158
EXPECT_EQ (nullptr , mysqlx_get_session_from_url (tmp.c_str (), &error));
3159
- tmp = std::string ( uri) + " compression=required&compression-algorithms=BAD_Algorithm" ;
3159
+ tmp = uri + " compression=required&compression-algorithms=BAD_Algorithm" ;
3160
3160
EXPECT_EQ (nullptr , mysqlx_get_session_from_url (tmp.c_str (), &error));
3161
- tmp = std::string ( uri) + " compression=required&compression-algorithms=[BAD_Algorithm]" ;
3161
+ tmp = uri + " compression=required&compression-algorithms=[BAD_Algorithm]" ;
3162
3162
EXPECT_EQ (nullptr , mysqlx_get_session_from_url (tmp.c_str (), &error));
3163
- tmp = std::string ( uri) + " compression=required&compression-algorithms=[BAD_Algorithm,BAD_Algorithm]" ;
3163
+ tmp = uri + " compression=required&compression-algorithms=[BAD_Algorithm,BAD_Algorithm]" ;
3164
3164
EXPECT_EQ (nullptr , mysqlx_get_session_from_url (tmp.c_str (), &error));
3165
3165
3166
3166
0 commit comments