mirror of
https://github.com/friendica/friendica
synced 2025-04-26 19:50:10 +00:00
Changing Friendica\App\Mode from static methods to public methods
- Changing from static methods to public methods - Adding dev-composer-dependency Mockery for static method mocking (f.e. Config, DBA) - Adding ModeTest with Mocking - removing bootstrap from phpunit.xml because of double loading tests\bootstrap.php
This commit is contained in:
parent
5014779052
commit
31148e25cf
21 changed files with 498 additions and 106 deletions
|
@ -39,7 +39,7 @@ HELP;
|
|||
|
||||
protected function doExecute()
|
||||
{
|
||||
$a = get_app();
|
||||
$a = \Friendica\BaseObject::getApp();
|
||||
|
||||
if ($this->getOption('v')) {
|
||||
$this->out('Class: ' . __CLASS__);
|
||||
|
@ -56,7 +56,7 @@ HELP;
|
|||
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
|
||||
}
|
||||
|
||||
if (App\Mode::isInstall()) {
|
||||
if ($a->getMode()->isInstall()) {
|
||||
throw new RuntimeException('Friendica isn\'t properly installed yet.');
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue