Skip to content
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.

Commit

Permalink
Fix unit tests error
Browse files Browse the repository at this point in the history
Fix unit tests error
  • Loading branch information
blanchonvincent committed Sep 8, 2012
1 parent b278ea4 commit 611e92a
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 17 deletions.
2 changes: 1 addition & 1 deletion tests/ZendTest/Paginator/AdapterPluginManagerTest.php
Expand Up @@ -18,7 +18,7 @@
* @subpackage UnitTests
* @group Zend_Paginator
*/
class FactoryTest extends \PHPUnit_Framework_TestCase
class AdapterPluginManagerTest extends \PHPUnit_Framework_TestCase
{
protected $adapaterPluginManager;

Expand Down
9 changes: 1 addition & 8 deletions tests/ZendTest/Paginator/FactoryTest.php
Expand Up @@ -12,6 +12,7 @@

use Zend\Paginator;
use Zend\Paginator\Adapter;
use ZendTest\Paginator\TestAsset\TestArrayAggregate;

/**
* @category Zend
Expand Down Expand Up @@ -42,12 +43,4 @@ public function testCanFactoryPaginatorWithStringAdapterAggregate()
$paginator = Paginator\Factory::Factory(null, new TestArrayAggregate);
$this->assertInstanceOf('Zend\Paginator\Adapter\ArrayAdapter', $paginator->getAdapter());
}
}

class TestArrayAggregate implements Paginator\AdapterAggregateInterface
{
public function getPaginatorAdapter()
{
return new Adapter\ArrayAdapter(array(1, 2, 3, 4));
}
}
9 changes: 1 addition & 8 deletions tests/ZendTest/Paginator/PaginatorTest.php
Expand Up @@ -23,6 +23,7 @@
use Zend\Paginator\Exception;
use Zend\View;
use Zend\View\Helper;
use ZendTest\Paginator\TestAsset\TestArrayAggregate;

/**
* @category Zend
Expand Down Expand Up @@ -796,11 +797,3 @@ public function testGetCacheId()
}

}

class TestArrayAggregate implements Paginator\AdapterAggregateInterface
{
public function getPaginatorAdapter()
{
return new Adapter\ArrayAdapter(array(1, 2, 3, 4));
}
}
27 changes: 27 additions & 0 deletions tests/ZendTest/Paginator/TestAsset/TestArrayAggregate.php
@@ -0,0 +1,27 @@
<?php
/**
* Zend Framework (http://framework.zend.com/)
*
* @link http://github.com/zendframework/zf2 for the canonical source repository
* @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
* @package Zend_Paginator
*/

namespace ZendTest\Paginator\TestAsset;

use Zend\Paginator;
use Zend\Paginator\Adapter;

/**
* @category Zend
* @package Zend_Paginator
* @subpackage UnitTests
*/
class TestArrayAggregate implements Paginator\AdapterAggregateInterface
{
public function getPaginatorAdapter()
{
return new Adapter\ArrayAdapter(array(1, 2, 3, 4));
}
}

0 comments on commit 611e92a

Please sign in to comment.