Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpmyadmin/phpmyadmin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorKamil Tekiela <tekiela246@gmail.com>2022-11-01 01:36:48 +0300
committerKamil Tekiela <tekiela246@gmail.com>2022-11-02 18:15:58 +0300
commita5a81d159fa919a412c24cad952fa6df2b3dfe76 (patch)
tree71826ea9df72758e35d0cd8774cfd5cfaf97aea3 /test
parent15915a45e094eeeab923eb73f4e55dfec1af99aa (diff)
Send DBI to Data using DI
Signed-off-by: Kamil Tekiela <tekiela246@gmail.com>
Diffstat (limited to 'test')
-rw-r--r--test/classes/Controllers/Server/Status/AdvisorControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/Monitor/GeneralLogControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/Monitor/LogVarsControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/Monitor/QueryAnalyzerControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/Monitor/SlowLogControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/MonitorControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/Processes/RefreshControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/ProcessesControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/QueriesControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/StatusControllerTest.php2
-rw-r--r--test/classes/Controllers/Server/Status/VariablesControllerTest.php2
11 files changed, 11 insertions, 11 deletions
diff --git a/test/classes/Controllers/Server/Status/AdvisorControllerTest.php b/test/classes/Controllers/Server/Status/AdvisorControllerTest.php
index ccc80b2037..fb6518fb38 100644
--- a/test/classes/Controllers/Server/Status/AdvisorControllerTest.php
+++ b/test/classes/Controllers/Server/Status/AdvisorControllerTest.php
@@ -42,7 +42,7 @@ class AdvisorControllerTest extends AbstractTestCase
$this->response = new ResponseRenderer();
$this->template = new Template();
- $this->data = new Data();
+ $this->data = new Data($GLOBALS['dbi']);
}
public function testIndexWithoutData(): void
diff --git a/test/classes/Controllers/Server/Status/Monitor/GeneralLogControllerTest.php b/test/classes/Controllers/Server/Status/Monitor/GeneralLogControllerTest.php
index 48b4edc25d..043f03a869 100644
--- a/test/classes/Controllers/Server/Status/Monitor/GeneralLogControllerTest.php
+++ b/test/classes/Controllers/Server/Status/Monitor/GeneralLogControllerTest.php
@@ -45,7 +45,7 @@ class GeneralLogControllerTest extends AbstractTestCase
$GLOBALS['cfg']['Server']['DisableIS'] = false;
$GLOBALS['cfg']['Server']['host'] = 'localhost';
- $this->data = new Data();
+ $this->data = new Data($this->dbi);
}
public function testGeneralLog(): void
diff --git a/test/classes/Controllers/Server/Status/Monitor/LogVarsControllerTest.php b/test/classes/Controllers/Server/Status/Monitor/LogVarsControllerTest.php
index 38fff4775c..cce986dc20 100644
--- a/test/classes/Controllers/Server/Status/Monitor/LogVarsControllerTest.php
+++ b/test/classes/Controllers/Server/Status/Monitor/LogVarsControllerTest.php
@@ -45,7 +45,7 @@ class LogVarsControllerTest extends AbstractTestCase
$GLOBALS['cfg']['Server']['DisableIS'] = false;
$GLOBALS['cfg']['Server']['host'] = 'localhost';
- $this->data = new Data();
+ $this->data = new Data($this->dbi);
}
public function testLogVars(): void
diff --git a/test/classes/Controllers/Server/Status/Monitor/QueryAnalyzerControllerTest.php b/test/classes/Controllers/Server/Status/Monitor/QueryAnalyzerControllerTest.php
index 5163e328cd..dd52e9398d 100644
--- a/test/classes/Controllers/Server/Status/Monitor/QueryAnalyzerControllerTest.php
+++ b/test/classes/Controllers/Server/Status/Monitor/QueryAnalyzerControllerTest.php
@@ -44,7 +44,7 @@ class QueryAnalyzerControllerTest extends AbstractTestCase
$dummyDbi = new DbiDummy();
$dbi = $this->createDatabaseInterface($dummyDbi);
- $controller = new QueryAnalyzerController($response, new Template(), new Data(), new Monitor($dbi), $dbi);
+ $controller = new QueryAnalyzerController($response, new Template(), new Data($dbi), new Monitor($dbi), $dbi);
$_POST['database'] = 'database';
$_POST['query'] = 'query';
diff --git a/test/classes/Controllers/Server/Status/Monitor/SlowLogControllerTest.php b/test/classes/Controllers/Server/Status/Monitor/SlowLogControllerTest.php
index e6545d22ff..6651c28a8e 100644
--- a/test/classes/Controllers/Server/Status/Monitor/SlowLogControllerTest.php
+++ b/test/classes/Controllers/Server/Status/Monitor/SlowLogControllerTest.php
@@ -45,7 +45,7 @@ class SlowLogControllerTest extends AbstractTestCase
$GLOBALS['cfg']['Server']['DisableIS'] = false;
$GLOBALS['cfg']['Server']['host'] = 'localhost';
- $this->data = new Data();
+ $this->data = new Data($this->dbi);
}
public function testSlowLog(): void
diff --git a/test/classes/Controllers/Server/Status/MonitorControllerTest.php b/test/classes/Controllers/Server/Status/MonitorControllerTest.php
index dc66b5dfa9..a608c0043b 100644
--- a/test/classes/Controllers/Server/Status/MonitorControllerTest.php
+++ b/test/classes/Controllers/Server/Status/MonitorControllerTest.php
@@ -46,7 +46,7 @@ class MonitorControllerTest extends AbstractTestCase
$GLOBALS['cfg']['Server']['DisableIS'] = false;
$GLOBALS['cfg']['Server']['host'] = 'localhost';
- $this->data = new Data();
+ $this->data = new Data($this->dbi);
}
public function testIndex(): void
diff --git a/test/classes/Controllers/Server/Status/Processes/RefreshControllerTest.php b/test/classes/Controllers/Server/Status/Processes/RefreshControllerTest.php
index c83e59f578..5fccaacb01 100644
--- a/test/classes/Controllers/Server/Status/Processes/RefreshControllerTest.php
+++ b/test/classes/Controllers/Server/Status/Processes/RefreshControllerTest.php
@@ -39,7 +39,7 @@ class RefreshControllerTest extends AbstractTestCase
$GLOBALS['cfg']['Server']['DisableIS'] = false;
$GLOBALS['cfg']['Server']['host'] = 'localhost';
- $this->data = new Data();
+ $this->data = new Data($GLOBALS['dbi']);
}
public function testRefresh(): void
diff --git a/test/classes/Controllers/Server/Status/ProcessesControllerTest.php b/test/classes/Controllers/Server/Status/ProcessesControllerTest.php
index daab49a4d0..a0ddb6e27c 100644
--- a/test/classes/Controllers/Server/Status/ProcessesControllerTest.php
+++ b/test/classes/Controllers/Server/Status/ProcessesControllerTest.php
@@ -45,7 +45,7 @@ class ProcessesControllerTest extends AbstractTestCase
$GLOBALS['cfg']['Server']['DisableIS'] = false;
$GLOBALS['cfg']['Server']['host'] = 'localhost';
- $this->data = new Data();
+ $this->data = new Data($this->dbi);
}
public function testIndex(): void
diff --git a/test/classes/Controllers/Server/Status/QueriesControllerTest.php b/test/classes/Controllers/Server/Status/QueriesControllerTest.php
index 00c35c5b38..ad080dd58e 100644
--- a/test/classes/Controllers/Server/Status/QueriesControllerTest.php
+++ b/test/classes/Controllers/Server/Status/QueriesControllerTest.php
@@ -49,7 +49,7 @@ class QueriesControllerTest extends AbstractTestCase
$GLOBALS['cfg']['Server']['DisableIS'] = false;
$GLOBALS['cfg']['Server']['host'] = 'localhost';
- $this->data = new Data();
+ $this->data = new Data($this->dbi);
$this->data->status['Uptime'] = 36000;
$this->data->usedQueries = [
'Com_change_db' => '15',
diff --git a/test/classes/Controllers/Server/Status/StatusControllerTest.php b/test/classes/Controllers/Server/Status/StatusControllerTest.php
index 925bab1d27..a1f8152147 100644
--- a/test/classes/Controllers/Server/Status/StatusControllerTest.php
+++ b/test/classes/Controllers/Server/Status/StatusControllerTest.php
@@ -46,7 +46,7 @@ class StatusControllerTest extends AbstractTestCase
public function testIndex(): void
{
- $data = new Data();
+ $data = new Data($GLOBALS['dbi']);
$bytesReceived = 100;
$bytesSent = 200;
diff --git a/test/classes/Controllers/Server/Status/VariablesControllerTest.php b/test/classes/Controllers/Server/Status/VariablesControllerTest.php
index 708dd8e803..48191dd2d5 100644
--- a/test/classes/Controllers/Server/Status/VariablesControllerTest.php
+++ b/test/classes/Controllers/Server/Status/VariablesControllerTest.php
@@ -44,7 +44,7 @@ class VariablesControllerTest extends AbstractTestCase
$GLOBALS['cfg']['Server']['DisableIS'] = false;
$GLOBALS['cfg']['Server']['host'] = 'localhost';
- $this->data = new Data();
+ $this->data = new Data($this->dbi);
}
public function testIndex(): void