spec\Newscoop\Gimme\PaginatorServiceSpec::it_should_paginate PHP Метод

it_should_paginate() публичный Метод

public it_should_paginate ( Pagination $pagination )
$pagination Newscoop\Gimme\Pagination
    function it_should_paginate(Pagination $pagination)
    {
        $this->setPagination($pagination);
        $this->setPaginationData(array('numItemsPerPage' => 5, 'current' => 2, 'totalCount' => 20, 'lastPageInRange' => 3, 'firstPageInRange' => 1));
        $this->paginate(array(1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20))->shouldReturn(array('items' => array(6, 7, 8, 9, 10), 'pagination' => array('itemsPerPage' => 5, 'currentPage' => 2, 'itemsCount' => 20, 'nextPageLink' => null, 'previousPageLink' => null)));
    }