mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-03-25 10:59:55 +00:00
Cleaning up code formatting on Paginator helper test, and adding extra test case
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6768 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
231d585221
commit
e2cca50ba9
1 changed files with 21 additions and 16 deletions
|
@ -172,22 +172,27 @@ class PaginatorTest extends UnitTestCase {
|
||||||
$this->Paginator->options = array();
|
$this->Paginator->options = array();
|
||||||
$this->Paginator->params = array();
|
$this->Paginator->params = array();
|
||||||
|
|
||||||
$options = array('paging' => array(
|
$options = array('paging' => array('Article' => array(
|
||||||
'Article' => array(
|
|
||||||
'order' => 'desc',
|
'order' => 'desc',
|
||||||
'sort' => 'title'
|
'sort' => 'title'
|
||||||
)
|
)));
|
||||||
)
|
|
||||||
);
|
|
||||||
$this->Paginator->options($options);
|
$this->Paginator->options($options);
|
||||||
|
|
||||||
$expected = array('Article' => array(
|
$expected = array('Article' => array(
|
||||||
'order' => 'desc',
|
'order' => 'desc',
|
||||||
'sort' => 'title'
|
'sort' => 'title'
|
||||||
)
|
));
|
||||||
);
|
|
||||||
$this->assertEqual($expected, $this->Paginator->params['paging']);
|
$this->assertEqual($expected, $this->Paginator->params['paging']);
|
||||||
|
|
||||||
|
$this->Paginator->options = array();
|
||||||
|
$this->Paginator->params = array();
|
||||||
|
|
||||||
|
$options = array('Article' => array(
|
||||||
|
'order' => 'desc',
|
||||||
|
'sort' => 'title'
|
||||||
|
));
|
||||||
|
$this->Paginator->options($options);
|
||||||
|
$this->assertEqual($expected, $this->Paginator->params['paging']);
|
||||||
}
|
}
|
||||||
|
|
||||||
function testPagingLinks() {
|
function testPagingLinks() {
|
||||||
|
|
Loading…
Add table
Reference in a new issue