mirror of
https://github.com/friendica/friendica
synced 2025-04-26 05:10:11 +00:00
friendica-6667 Installer needs to check fileinfo module
This commit is contained in:
parent
12ff467a9b
commit
11a7f97fe7
2 changed files with 23 additions and 1 deletions
|
@ -45,6 +45,8 @@ class InstallerTest extends MockedTest
|
|||
$this->mockL10nT('Error: POSIX PHP module required but not installed.', 1);
|
||||
$this->mockL10nT('JSON PHP module', 1);
|
||||
$this->mockL10nT('Error: JSON PHP module required but not installed.', 1);
|
||||
$this->mockL10nT('File Information PHP module', 1);
|
||||
$this->mockL10nT('Error: File Information PHP module required but not installed.', 1);
|
||||
}
|
||||
|
||||
private function assertCheckExist($position, $title, $help, $status, $required, $assertionArray)
|
||||
|
@ -192,6 +194,17 @@ class InstallerTest extends MockedTest
|
|||
true,
|
||||
$install->getChecks());
|
||||
|
||||
$this->mockFunctionL10TCalls();
|
||||
$this->setFunctions(['finfo_open' => false]);
|
||||
$install = new Installer();
|
||||
$this->assertFalse($install->checkFunctions());
|
||||
$this->assertCheckExist(10,
|
||||
'File Information PHP module',
|
||||
'Error: File Information PHP module required but not installed.',
|
||||
false,
|
||||
true,
|
||||
$install->getChecks());
|
||||
|
||||
$this->mockFunctionL10TCalls();
|
||||
$this->setFunctions([
|
||||
'curl_init' => true,
|
||||
|
@ -200,7 +213,8 @@ class InstallerTest extends MockedTest
|
|||
'mb_strlen' => true,
|
||||
'iconv_strlen' => true,
|
||||
'posix_kill' => true,
|
||||
'json_encode' => true
|
||||
'json_encode' => true,
|
||||
'finfo_open' => true,
|
||||
]);
|
||||
$install = new Installer();
|
||||
$this->assertTrue($install->checkFunctions());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue