@@ -19,7 +19,7 @@ const (
19
19
)
20
20
21
21
func TestBuilder (t * testing.T ) {
22
- ctx := pagehelper .C (context .Background ()).Page (1 , 3 ).Order ("test" , pagehelper .ASC ).Build ()
22
+ ctx := pagehelper .C (context .Background ()).Page (1 , 3 ).OrderBy ("test" , pagehelper .ASC ).Build ()
23
23
ctx , _ = context .WithTimeout (ctx , time .Second )
24
24
p := ctx .Value (pageHelperValue )
25
25
o := ctx .Value (orderHelperValue )
@@ -29,7 +29,7 @@ func TestBuilder(t *testing.T) {
29
29
}
30
30
31
31
func TestBuilder2 (t * testing.T ) {
32
- ctx := pagehelper .C (context .Background ()).PageWithCount (1 , 3 , "" ).Order ("test" , pagehelper .ASC ).Build ()
32
+ ctx := pagehelper .C (context .Background ()).PageWithCount (1 , 3 , "" ).OrderBy ("test" , pagehelper .ASC ).Build ()
33
33
ctx = pagehelper .C (ctx ).DESC ("new_field" ).Build ()
34
34
ctx , _ = context .WithTimeout (ctx , time .Second )
35
35
p := ctx .Value (pageHelperValue )
@@ -40,7 +40,7 @@ func TestBuilder2(t *testing.T) {
40
40
}
41
41
42
42
func TestBuilder3 (t * testing.T ) {
43
- ctx := pagehelper .C (context .Background ()).Page (1 , 3 ).Order ("test" , pagehelper .ASC ).Build ()
43
+ ctx := pagehelper .C (context .Background ()).Page (1 , 3 ).OrderBy ("test" , pagehelper .ASC ).Build ()
44
44
ctx = pagehelper .C (ctx ).DESC ("new_field" ).ASC ("new_field2" ).Count ("test" ).Page (2 ,100 ).Build ()
45
45
ctx , _ = context .WithTimeout (ctx , time .Second )
46
46
p := ctx .Value (pageHelperValue )
0 commit comments