File tree Expand file tree Collapse file tree 2 files changed +1
-21
lines changed
test/Github/Tests/Integration Expand file tree Collapse file tree 2 files changed +1
-21
lines changed Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ abstract class AbstractApi
20
20
private $ client ;
21
21
22
22
/**
23
- * The per page parameter.
23
+ * The per page parameter. It is used by the ResultPager.
24
24
*
25
25
* @var int|null
26
26
*/
Original file line number Diff line number Diff line change 9
9
*/
10
10
class ResultPagerTest extends TestCase
11
11
{
12
- /**
13
- * @test
14
- */
15
- public function shouldPaginateGetRequests ()
16
- {
17
- $ repositoriesApi = $ this ->client ->api ('user ' );
18
- $ repositoriesApi ->setPerPage (10 );
19
-
20
- $ pager = $ this ->createPager ();
21
-
22
- $ repositories = $ pager ->fetch ($ repositoriesApi , 'repositories ' , ['KnpLabs ' ]);
23
- $ this ->assertCount (10 , $ repositories );
24
-
25
- $ repositoriesApi ->setPerPage (20 );
26
- $ repositories = $ pager ->fetch ($ repositoriesApi , 'repositories ' , ['KnpLabs ' ]);
27
- $ this ->assertCount (20 , $ repositories );
28
- }
29
-
30
12
/**
31
13
* @test
32
14
*
@@ -43,10 +25,8 @@ public function shouldPaginateGetRequests()
43
25
public function shouldGetAllResultsFromSearchApi ()
44
26
{
45
27
$ searchApi = $ this ->client ->search ();
46
- $ searchApi ->setPerPage (10 );
47
28
48
29
$ pager = $ this ->createPager ();
49
-
50
30
$ users = $ pager ->fetch ($ searchApi , 'users ' , ['location:Kyiv ' ]);
51
31
$ this ->assertCount (10 , $ users );
52
32
}
You can’t perform that action at this time.
0 commit comments