dummyDbi = $this->createDbiDummy(); $this->dbi = $this->createDatabaseInterface($this->dummyDbi); $GLOBALS['dbi'] = $this->dbi; $GLOBALS['text_dir'] = 'ltr'; $GLOBALS['server'] = 1; $GLOBALS['db'] = 'db'; $GLOBALS['table'] = 'table'; $GLOBALS['cfg']['Server']['DisableIS'] = false; $GLOBALS['cfg']['Server']['host'] = 'localhost'; $this->data = new Data($this->dbi, $GLOBALS['config']); } public function testIndex(): void { $response = new ResponseRenderer(); $controller = new VariablesController($response, new Template(), $this->data, $GLOBALS['dbi']); $this->dummyDbi->addSelectDb('mysql'); $controller($this->createStub(ServerRequest::class)); $this->dummyDbi->assertAllSelectsConsumed(); $html = $response->getHTMLResult(); $this->assertStringContainsString('
', $html); $this->assertStringContainsString('index.php?route=/server/status/variables', $html); $this->assertStringContainsString( '', $html, ); $this->assertStringContainsString('