File tree Expand file tree Collapse file tree 3 files changed +13
-13
lines changed Expand file tree Collapse file tree 3 files changed +13
-13
lines changed Original file line number Diff line number Diff line change @@ -186,7 +186,7 @@ func TestQueryString(t *testing.T) {
186
186
r := gofight.New ()
187
187
188
188
r.GET (" /hello" ).
189
- SetQUERY (gofight.H {
189
+ SetQuery (gofight.H {
190
190
" a" : " 1" ,
191
191
" b" : " 2" ,
192
192
}).
@@ -203,7 +203,7 @@ func TestQueryString(t *testing.T) {
203
203
r := gofight.New ()
204
204
205
205
r.GET (" /hello?foo=bar" ).
206
- SetQUERY (gofight.H {
206
+ SetQuery (gofight.H {
207
207
" a" : " 1" ,
208
208
" b" : " 2" ,
209
209
}).
Original file line number Diff line number Diff line change 14
14
// "X-Version": version,
15
15
// })
16
16
//
17
- // Set query string: Using SetQUERY to generate query string data.
17
+ // Set query string: Using SetQuery to generate query string data.
18
18
//
19
- // SetQUERY (gofight.H{
19
+ // SetQuery (gofight.H{
20
20
// "a": "1",
21
21
// "b": "2",
22
22
// })
23
23
//
24
- // POST FORM Data: Using SetFORM to generate form data.
24
+ // POST FORM Data: Using SetForm to generate form data.
25
25
//
26
- // SetFORM (gofight.H{
26
+ // SetForm (gofight.H{
27
27
// "a": "1",
28
28
// "b": "2",
29
29
// })
@@ -206,8 +206,8 @@ func (rc *RequestConfig) SetJSON(body D) *RequestConfig {
206
206
return rc
207
207
}
208
208
209
- // SetFORM supply form body.
210
- func (rc * RequestConfig ) SetFORM (body H ) * RequestConfig {
209
+ // SetForm supply form body.
210
+ func (rc * RequestConfig ) SetForm (body H ) * RequestConfig {
211
211
f := make (url.Values )
212
212
213
213
for k , v := range body {
@@ -219,8 +219,8 @@ func (rc *RequestConfig) SetFORM(body H) *RequestConfig {
219
219
return rc
220
220
}
221
221
222
- // SetQUERY supply query string.
223
- func (rc * RequestConfig ) SetQUERY (query H ) * RequestConfig {
222
+ // SetQuery supply query string.
223
+ func (rc * RequestConfig ) SetQuery (query H ) * RequestConfig {
224
224
f := make (url.Values )
225
225
226
226
for k , v := range query {
Original file line number Diff line number Diff line change @@ -97,7 +97,7 @@ func TestGinPostFormData(t *testing.T) {
97
97
r := New ()
98
98
99
99
r .POST ("/form" ).
100
- SetFORM (H {
100
+ SetForm (H {
101
101
"a" : "1" ,
102
102
"b" : "2" ,
103
103
}).
@@ -385,15 +385,15 @@ func TestSetQueryString(t *testing.T) {
385
385
r := New ()
386
386
387
387
r .GET ("/hello" ).
388
- SetQUERY (H {
388
+ SetQuery (H {
389
389
"a" : "1" ,
390
390
"b" : "2" ,
391
391
})
392
392
393
393
assert .Equal (t , "/hello?a=1&b=2" , r .Path )
394
394
395
395
r .GET ("/hello?foo=bar" ).
396
- SetQUERY (H {
396
+ SetQuery (H {
397
397
"a" : "1" ,
398
398
"b" : "2" ,
399
399
})
You can’t perform that action at this time.
0 commit comments