for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* @license LGPLv3, http://opensource.org/licenses/LGPL-3.0
* @copyright Aimeos (aimeos.org), 2020-2022
*/
namespace Aimeos\Base\View\Helper\Typemap;
class StandardTest extends \PHPUnit\Framework\TestCase
{
private $object;
protected function setUp() : void
$view = new \Aimeos\Base\View\Standard();
$this->object = new \Aimeos\Base\View\Helper\Typemap\Standard( $view );
}
protected function tearDown() : void
unset( $this->object );
public function testTransform()
$manager = \Aimeos\MShop::create( \TestHelper::context(), 'attribute' );
$items = $manager->search( $manager->filter()->slice( 0, 1 ) );
$result = $this->object->transform( $items );
$this->assertCount( 1, $result );
$this->assertIsArray( $result->first() );