method('getParsedBodyParam')->willReturnMap([['collation_connection', null, 'utf8mb4_general_ci']]); $response = self::createMock(ResponseRenderer::class); $response->expects(self::once())->method('redirect') ->with('index.php?route=/' . Url::getCommonRaw([], '&')); $response->expects(self::once())->method('response')->willReturn(ResponseFactory::create()->createResponse()); $config = self::createMock(Config::class); $config->expects(self::once())->method('setUserValue') ->with(null, 'DefaultConnectionCollation', 'utf8mb4_general_ci', 'utf8mb4_unicode_ci'); (new CollationConnectionController($response, $config))($request); } }