public static function registerFeatureFlags($scope, array $versionedFeatureFlags, $deprecationWarnings = FALSE)
{
if (TRUE === $deprecationWarnings && NULL === static::resolveVersionedValue($versionedFeatureFlags, self::VERSION_DEFAULT)) {
GeneralUtility::deprecationLog(sprintf('FluidTYPO3.Flux: CompatibilityRegistry was given versioned feature flags in scope %s but the versioned ' . 'values do not contain at least one set that applies on this version (%s)', $scope, static::resolveVersion(self::VERSION_DEFAULT)));
}
static::$featureFlags[$scope] = $versionedFeatureFlags;
}
/** * @param array $versionedValues * @param string $version * @param mixed $flag * @param mixed $expected * @test * @dataProvider getRegisterAndRetrieveFeatureFlagTestValues */ public function testRegisterAndRetieveFeatureFlag(array $versionedValues, $version, $flag, $expected) { CompatibilityRegistry::registerFeatureFlags($scope, $versionedValues, FALSE); $this->assertEquals($expected, CompatibilityRegistry::hasFeatureFlag($scope, $flag, $version)); }