]> git.mxchange.org Git - friendica.git/blobdiff - tests/src/Core/Console/AutomaticInstallationConsoleTest.php
Merge branch '2019.03-RC'
[friendica.git] / tests / src / Core / Console / AutomaticInstallationConsoleTest.php
index 29a0e907e5cb702104cc91cae04ec42040e28fc5..73b6835fb5cce41a46731c4a800079a978beab1d 100644 (file)
@@ -47,12 +47,15 @@ class AutomaticInstallationConsoleTest extends ConsoleTest
                }
 
                $this->db_host = getenv('MYSQL_HOST');
-               $this->db_port = (!empty(getenv('MYSQL_PORT'))) ? getenv('MYSQL_PORT') : null;
+               $this->db_port = !empty(getenv('MYSQL_PORT')) ? getenv('MYSQL_PORT') : null;
                $this->db_data = getenv('MYSQL_DATABASE');
                $this->db_user = getenv('MYSQL_USERNAME') . getenv('MYSQL_USER');
                $this->db_pass = getenv('MYSQL_PASSWORD');
 
-               $this->mockConfigGet('config', 'php_path', false);
+               $this->configMock
+                       ->shouldReceive('get')
+                       ->with('config', 'php_path')
+                       ->andReturn(false);
 
                $this->mockL10nT();
        }
@@ -181,7 +184,7 @@ FIN;
                $this->mockConnect(true, 1);
                $this->mockConnected(true, 1);
                $this->mockExistsTable('user', false, 1);
-               $this->mockUpdate([false, true, true], null, 1);
+               $this->mockUpdate([$this->root->url(), false, true, true], null, 1);
 
                $config = <<<CONF
 <?php
@@ -209,7 +212,7 @@ return [
        'config' => [
                'admin_email' => '',
                'sitename' => 'Friendica Social Network',
-               'register_policy' => REGISTER_OPEN,
+               'register_policy' => \Friendica\Module\Register::OPEN,
                'register_text' => '',
        ],
        'system' => [
@@ -241,7 +244,7 @@ CONF;
                $this->mockConnect(true, 1);
                $this->mockConnected(true, 1);
                $this->mockExistsTable('user', false, 1);
-               $this->mockUpdate([false, true, true], null, 1);
+               $this->mockUpdate([$this->root->url(), false, true, true], null, 1);
 
                $this->mockGetMarkupTemplate('local.config.tpl', 'testTemplate', 1);
                $this->mockReplaceMacros('testTemplate', $this->createArgumentsForMacro(true), '', 1);
@@ -267,7 +270,7 @@ CONF;
                $this->mockConnect(true, 1);
                $this->mockConnected(true, 1);
                $this->mockExistsTable('user', false, 1);
-               $this->mockUpdate([false, true, true], null, 1);
+               $this->mockUpdate([$this->root->url(), false, true, true], null, 1);
 
                $this->mockGetMarkupTemplate('local.config.tpl', 'testTemplate', 1);
                $this->mockReplaceMacros('testTemplate', $this->createArgumentsForMacro(false), '', 1);
@@ -292,7 +295,7 @@ CONF;
                $this->mockConnect(true, 1);
                $this->mockConnected(true, 1);
                $this->mockExistsTable('user', false, 1);
-               $this->mockUpdate([false, true, true], null, 1);
+               $this->mockUpdate([$this->root->url(), false, true, true], null, 1);
 
                $this->mockGetMarkupTemplate('local.config.tpl', 'testTemplate', 1);
                $this->mockReplaceMacros('testTemplate', $this->createArgumentsForMacro(true), '', 1);