@@ -221,20 +221,21 @@ func TestInterpolateParamsWithComments(t *testing.T) {
221
221
shouldSkip bool
222
222
}{
223
223
// ? in single-line comment (--) should not be replaced
224
- {"SELECT 1 -- ?\n , ?" , []driver.Value {42 }, "SELECT 1 -- ?\n , 42" , false },
224
+ {"SELECT 1 -- ?\n , ?" , []driver.Value {int64 ( 42 ) }, "SELECT 1 -- ?\n , 42" , false },
225
225
// ? in single-line comment (#) should not be replaced
226
- {"SELECT 1 # ?\n , ?" , []driver.Value {42 }, "SELECT 1 # ?\n , 42" , false },
226
+ {"SELECT 1 # ?\n , ?" , []driver.Value {int64 ( 42 ) }, "SELECT 1 # ?\n , 42" , false },
227
227
// ? in multi-line comment should not be replaced
228
- {"SELECT /* ? */ ?" , []driver.Value {42 }, "SELECT /* ? */ 42" , false },
228
+ {"SELECT /* ? */ ?" , []driver.Value {int64 ( 42 ) }, "SELECT /* ? */ 42" , false },
229
229
// ? in string literal should not be replaced
230
- {"SELECT '?', ?" , []driver.Value {42 }, "SELECT '?', 42" , false },
230
+ {"SELECT '?', ?" , []driver.Value {int64 ( 42 ) }, "SELECT '?', 42" , false },
231
231
// ? in backtick identifier should not be replaced
232
- {"SELECT `?`, ?" , []driver.Value {42 }, "SELECT `?`, 42" , false },
232
+ {"SELECT `?`, ?" , []driver.Value {int64 ( 42 ) }, "SELECT `?`, 42" , false },
233
233
// Multiple comments and real placeholders
234
- {"SELECT ? -- comment ?\n , ? /* ? */ , ? # ?\n , ?" , []driver.Value {1 , 2 , 3 }, "SELECT 1 -- comment ?\n , 2 /* ? */ , 3 # ?\n , ?" , true },
234
+ {"SELECT ? -- comment ?\n , ? /* ? */ , ? # ?\n , ?" , []driver.Value {int64 ( 1 ), int64 ( 2 ), int64 ( 3 ) }, "SELECT 1 -- comment ?\n , 2 /* ? */ , 3 # ?\n , ?" , true },
235
235
}
236
236
237
237
for i , test := range tests {
238
+
238
239
q , err := mc .interpolateParams (test .query , test .args )
239
240
if test .shouldSkip {
240
241
if err != driver .ErrSkip {
0 commit comments