本文整理汇总了PHP中TestHelper::getControllerPaths方法的典型用法代码示例。如果您正苦于以下问题:PHP TestHelper::getControllerPaths方法的具体用法?PHP TestHelper::getControllerPaths怎么用?PHP TestHelper::getControllerPaths使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TestHelper
的用法示例。
在下文中一共展示了TestHelper::getControllerPaths方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: testGetControllers
public function testGetControllers()
{
$context = \TestHelper::getContext();
$aimeos = \TestHelper::getAimeos();
$list = \Aimeos\Controller\Jobs\Factory::getControllers($context, $aimeos, \TestHelper::getControllerPaths());
$this->assertGreaterThan(0, count($list));
foreach ($list as $key => $object) {
$this->assertInstanceOf('\\Aimeos\\Controller\\Jobs\\Iface', $object);
}
}
示例2: testGetControllers
public function testGetControllers()
{
$context = TestHelper::getContext();
$arcavias = TestHelper::getArcavias();
$list = Controller_Jobs_Factory::getControllers($context, $arcavias, TestHelper::getControllerPaths());
$this->assertGreaterThan(0, count($list));
foreach ($list as $key => $object) {
$this->assertInstanceOf('Controller_Jobs_Interface', $object);
}
}
示例3: testClearSpecific
public function testClearSpecific()
{
$cache = \Aimeos\Controller\Jsonapi\Factory::setCache(true);
$context = \TestHelper::getContext();
$templatePaths = \TestHelper::getControllerPaths();
$cntlA1 = \Aimeos\Controller\Jsonapi\Factory::createController($context, $templatePaths, 'attribute');
$cntlB1 = \Aimeos\Controller\Jsonapi\Factory::createController($context, $templatePaths, 'attribute/lists/type');
\Aimeos\Controller\Jsonapi\Factory::clear((string) $context, 'attribute');
$cntlA2 = \Aimeos\Controller\Jsonapi\Factory::createController($context, $templatePaths, 'attribute');
$cntlB2 = \Aimeos\Controller\Jsonapi\Factory::createController($context, $templatePaths, 'attribute/lists/type');
\Aimeos\Controller\Jsonapi\Factory::setCache($cache);
$this->assertNotSame($cntlA1, $cntlA2);
$this->assertSame($cntlB1, $cntlB2);
}
示例4: setUpBeforeClass
public static function setUpBeforeClass()
{
$cntlPaths = \TestHelper::getControllerPaths();
self::$object = new \Aimeos\Controller\ExtJS\JsonRpc(\TestHelper::getContext(), $cntlPaths);
}
示例5: setUpBeforeClass
public static function setUpBeforeClass()
{
$cntlPaths = TestHelper::getControllerPaths();
self::$_object = new Controller_ExtJS_JsonRpc(TestHelper::getContext(), $cntlPaths);
}
示例6: testGetInvalid
public function testGetInvalid()
{
$header = array();
$status = 500;
$templatePaths = \TestHelper::getControllerPaths();
$object = new \Aimeos\Controller\Jsonapi\Standard($this->context, $templatePaths, 'invalid');
$result = json_decode($object->get('', $header, $status), true);
$this->assertEquals(404, $status);
$this->assertEquals(1, count($header));
$this->assertEquals(1, count($result['errors']));
$this->assertArrayHasKey('title', $result['errors'][0]);
$this->assertArrayHasKey('detail', $result['errors'][0]);
$this->assertArrayNotHasKey('data', $result);
$this->assertArrayNotHasKey('indluded', $result);
}