当前位置: 首页>>代码示例>>PHP>>正文


PHP Fixture::loadAllPlugins方法代码示例

本文整理汇总了PHP中Piwik\Tests\Framework\Fixture::loadAllPlugins方法的典型用法代码示例。如果您正苦于以下问题:PHP Fixture::loadAllPlugins方法的具体用法?PHP Fixture::loadAllPlugins怎么用?PHP Fixture::loadAllPlugins使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Piwik\Tests\Framework\Fixture的用法示例。


在下文中一共展示了Fixture::loadAllPlugins方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getApiForTesting

 public function getApiForTesting()
 {
     // we will test all segments from all plugins
     Fixture::loadAllPlugins();
     $apiToCall = array('VisitsSummary.get', 'CustomVariables.getCustomVariables');
     return array(array($apiToCall, array('idSite' => 'all', 'date' => self::$fixture->dateTime, 'periods' => array('day', 'week'), 'setDateLastN' => true, 'segment' => $this->getSegmentToTest())));
 }
开发者ID:TensorWrenchOSS,项目名称:piwik,代码行数:7,代码来源:TwoVisitsWithCustomVariablesSegmentMatchNONETest.php

示例2: setUp

 /**
  * Setup the database and create the base tables for all tests
  */
 public function setUp()
 {
     parent::setUp();
     static::$fixture->extraDefinitions = array_merge(static::provideContainerConfigBeforeClass(), $this->provideContainerConfig());
     static::$fixture->createEnvironmentInstance();
     Db::createDatabaseObject();
     Fixture::loadAllPlugins(new TestingEnvironmentVariables(), get_class($this), self::$fixture->extraPluginsToLoad);
     Access::getInstance()->setSuperUserAccess(true);
     if (!empty(self::$tableData)) {
         self::restoreDbTables(self::$tableData);
     }
     PiwikCache::getEagerCache()->flushAll();
     PiwikCache::getTransientCache()->flushAll();
     MenuAbstract::clearMenus();
 }
开发者ID:hichnik,项目名称:piwik,代码行数:18,代码来源:IntegrationTestCase.php

示例3: getApiForTesting

 public function getApiForTesting()
 {
     // we will test all segments from all plugins
     Fixture::loadAllPlugins();
     $idSite = self::$fixture->idSite;
     $apiForTesting = array();
     $segments = \Piwik\Plugins\API\API::getInstance()->getSegmentsMetadata(self::$fixture->idSite);
     foreach ($segments as $segment) {
         $apiForTesting[] = $this->getApiForTestingForSegment($idSite, $segment['segment']);
     }
     if (self::isMysqli() || self::isTravisCI()) {
         // Skip the test on Mysqli as it fails due to rounding Float errors on latitude/longitude
         // then the test started failing after bc19503 and I cannot understand why
         echo "Skipped test \n";
     } else {
         $apiForTesting[] = array('Live.getLastVisitsDetails', array('idSite' => $idSite, 'date' => '1998-07-12,today', 'period' => 'range', 'otherRequestParameters' => array('filter_limit' => 1000)));
     }
     return $apiForTesting;
 }
开发者ID:ahdinosaur,项目名称:analytics.dinosaur.is,代码行数:19,代码来源:AutoSuggestAPITest.php


注:本文中的Piwik\Tests\Framework\Fixture::loadAllPlugins方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。