55namespace PhpMyAdmin \Tests \Controllers \Database ;
66
77use PhpMyAdmin \ConfigStorage \Relation ;
8- use PhpMyAdmin \ConfigStorage \RelationCleanup ;
98use PhpMyAdmin \Controllers \Database \StructureController ;
109use PhpMyAdmin \DatabaseInterface ;
11- use PhpMyAdmin \FlashMessages ;
1210use PhpMyAdmin \Http \ServerRequest ;
13- use PhpMyAdmin \Operations ;
1411use PhpMyAdmin \Replication ;
1512use PhpMyAdmin \Table ;
1613use PhpMyAdmin \Template ;
@@ -36,15 +33,6 @@ class StructureControllerTest extends AbstractTestCase
3633 /** @var Template */
3734 private $ template ;
3835
39- /** @var RelationCleanup */
40- private $ relationCleanup ;
41-
42- /** @var Operations */
43- private $ operations ;
44-
45- /** @var FlashMessages */
46- private $ flash ;
47-
4836 /**
4937 * Prepares environment for the test.
5038 */
@@ -80,9 +68,6 @@ protected function setUp(): void
8068 $ this ->response = new ResponseStub ();
8169 $ this ->relation = new Relation ($ dbi );
8270 $ this ->replication = new Replication ();
83- $ this ->relationCleanup = new RelationCleanup ($ dbi , $ this ->relation );
84- $ this ->operations = new Operations ($ dbi , $ this ->relation );
85- $ this ->flash = new FlashMessages ();
8671 }
8772
8873 /**
@@ -98,10 +83,7 @@ public function testGetValuesForInnodbTable(): void
9883 $ this ->template ,
9984 $ this ->relation ,
10085 $ this ->replication ,
101- $ this ->relationCleanup ,
102- $ this ->operations ,
103- $ GLOBALS ['dbi ' ],
104- $ this ->flash
86+ $ GLOBALS ['dbi ' ]
10587 );
10688 // Showing statistics
10789 $ property = $ class ->getProperty ('isShowStats ' );
@@ -145,10 +127,7 @@ public function testGetValuesForInnodbTable(): void
145127 $ this ->template ,
146128 $ this ->relation ,
147129 $ this ->replication ,
148- $ this ->relationCleanup ,
149- $ this ->operations ,
150- $ GLOBALS ['dbi ' ],
151- $ this ->flash
130+ $ GLOBALS ['dbi ' ]
152131 );
153132
154133 $ currentTable ['ENGINE ' ] = 'InnoDB ' ;
@@ -176,10 +155,7 @@ public function testGetValuesForAriaTable(): void
176155 $ this ->template ,
177156 $ this ->relation ,
178157 $ this ->replication ,
179- $ this ->relationCleanup ,
180- $ this ->operations ,
181- $ GLOBALS ['dbi ' ],
182- $ this ->flash
158+ $ GLOBALS ['dbi ' ]
183159 );
184160 // Showing statistics
185161 $ property = $ class ->getProperty ('isShowStats ' );
@@ -231,10 +207,7 @@ public function testGetValuesForAriaTable(): void
231207 $ this ->template ,
232208 $ this ->relation ,
233209 $ this ->replication ,
234- $ this ->relationCleanup ,
235- $ this ->operations ,
236- $ GLOBALS ['dbi ' ],
237- $ this ->flash
210+ $ GLOBALS ['dbi ' ]
238211 );
239212 [$ currentTable , , , , , , $ sumSize ] = $ method ->invokeArgs (
240213 $ controller ,
@@ -255,10 +228,7 @@ public function testGetValuesForAriaTable(): void
255228 $ this ->template ,
256229 $ this ->relation ,
257230 $ this ->replication ,
258- $ this ->relationCleanup ,
259- $ this ->operations ,
260- $ GLOBALS ['dbi ' ],
261- $ this ->flash
231+ $ GLOBALS ['dbi ' ]
262232 );
263233 [$ currentTable ] = $ method ->invokeArgs (
264234 $ controller ,
@@ -289,10 +259,7 @@ public function testHasTable(): void
289259 $ this ->template ,
290260 $ this ->relation ,
291261 $ this ->replication ,
292- $ this ->relationCleanup ,
293- $ this ->operations ,
294- $ GLOBALS ['dbi ' ],
295- $ this ->flash
262+ $ GLOBALS ['dbi ' ]
296263 );
297264
298265 // When parameter $db is empty
@@ -327,10 +294,7 @@ public function testCheckFavoriteTable(): void
327294 $ this ->template ,
328295 $ this ->relation ,
329296 $ this ->replication ,
330- $ this ->relationCleanup ,
331- $ this ->operations ,
332- $ GLOBALS ['dbi ' ],
333- $ this ->flash
297+ $ GLOBALS ['dbi ' ]
334298 );
335299
336300 $ _SESSION ['tmpval ' ]['favoriteTables ' ][$ GLOBALS ['server ' ]] = [
@@ -363,10 +327,7 @@ public function testDisplayTableList(): void
363327 $ this ->template ,
364328 $ this ->relation ,
365329 $ this ->replication ,
366- $ this ->relationCleanup ,
367- $ this ->operations ,
368- $ GLOBALS ['dbi ' ],
369- $ this ->flash
330+ $ GLOBALS ['dbi ' ]
370331 );
371332 // Showing statistics
372333 $ class = new ReflectionClass (StructureController::class);
0 commit comments