);
$returnVal = $returnVal ? $status : false;
- $status = $this->checkFunction('json_encode',
- L10n::t('JSON PHP module'),
- L10n::t('Error: JSON PHP module required but not installed.'),
- true
- );
- $returnVal = $returnVal ? $status : false;
-
$status = $this->checkFunction('imagecreatefromjpeg',
L10n::t('GD graphics PHP module'),
L10n::t('Error: GD graphics PHP module with JPEG support required but not installed.'),
);
$returnVal = $returnVal ? $status : false;
+ $status = $this->checkFunction('json_encode',
+ L10n::t('JSON PHP module'),
+ L10n::t('Error: JSON PHP module required but not installed.'),
+ true
+ );
+ $returnVal = $returnVal ? $status : false;
+
return $returnVal;
}
true,
$install->getChecks());
+ $this->mockFunctionL10TCalls();
+ $this->setFunctions(['json_encode' => false]);
+ $install = new Installer();
+ $this->assertFalse($install->checkFunctions());
+ $this->assertCheckExist(9,
+ 'JSON PHP module',
+ 'Error: JSON PHP module required but not installed.',
+ false,
+ true,
+ $install->getChecks());
+
$this->mockFunctionL10TCalls();
$this->setFunctions([
'curl_init' => true,